Changeset 1eed4e in git


Ignore:
Timestamp:
May 3, 1997, 7:23:33 PM (27 years ago)
Author:
Olaf Bachmann <obachman@…>
Branches:
(u'spielwiese', '82fc009ea2b0098c1a4896c841bb70860976bdfc')
Children:
126cfafa551d9e07946af2c86b0a4724c46e6887
Parents:
a492d244011973fae73429206423e59369d4e872
Message:
Sat May  3 00:07:55 1997  Olaf Bachmann
<obachman@ratchwum.mathematik.uni-kl.de (Olaf Bachmann)>

	* febase.cc (feFopen): fixed bug in opening library from
	  SINGULAR_DATADIR: SINGULAR_DATADIR is appended to
	  getenv("SINGULARPATH")


git-svn-id: file:///usr/local/Singular/svn/trunk@233 2c84dea3-7e68-4137-9b89-c4e89433aadc
Location:
Singular
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • Singular/ChangeLog

    ra492d2 r1eed4e  
    11Sat May  3 00:07:55 1997  Olaf Bachmann  <obachman@ratchwum.mathematik.uni-kl.de (Olaf Bachmann)>
     2
     3        * febase.cc (feFopen): fixed bug in opening library from
     4          SINGULAR_DATADIR: SINGULAR_DATADIR is appended to
     5          getenv("SINGULARPATH")
    26
    37        * small mpsr Changes to reflect some name changes of MP Dicts
  • Singular/febase.cc

    ra492d2 r1eed4e  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: febase.cc,v 1.15 1997-05-02 15:10:11 Singular Exp $ */
     4/* $Id: febase.cc,v 1.16 1997-05-03 17:23:33 obachman Exp $ */
    55/*
    66* ABSTRACT: i/o system, handling of 'voices'
     
    159159    #endif
    160160    char *s;
     161    #ifndef macintosh
     162    // extend path by SINGULAR_DATADIR
     163    s = (char*) AllocL(strlen(env)+strlen(SINGULAR_DATADIR)+2);
     164    if (env != NULL)
     165    {
     166      strcpy(s, env);
     167      s[strlen(env)] = FS_SEP;
     168      s[strlen(env)+1] = '\0';
     169      strcat(s, SINGULAR_DATADIR);
     170    }
     171    else strcpy(s, SINGULAR_DATADIR);
     172    env = s;
     173    #endif
    161174    if (where==NULL) s=(char *)AllocL(250);
    162175    else             s=where;
     
    199212    }
    200213    #ifndef macintosh
    201       if (f==NULL)
    202       {
    203         char* ss = s;
    204         int need_len = strlen(path) + strlen(SINGULAR_DATADIR) + 2;
    205 
    206         if (where == NULL)
    207         {
    208           if (need_len > 250) ss = (char *) AllocL(need_len);
    209           strcpy(ss,s);
    210         }
    211         else
    212         {
    213           if (need_len > strlen(where)) ss = (char *) AllocL(need_len);
    214           strcpy(ss, s);
    215         }
    216         strcpy(ss,SINGULAR_DATADIR);
    217         strcat(s, DIR_SEPP);
    218         strcat(ss,path);
    219         f=fopen(ss,mode);
    220         if (ss != s) FreeL((ADDRESS)ss);
    221       }
     214    FreeL(env);
    222215    #endif
    223216    if (where==NULL) FreeL((ADDRESS)s);
Note: See TracChangeset for help on using the changeset viewer.