Changeset df595d in git for Singular/misc.cc


Ignore:
Timestamp:
Apr 27, 1998, 12:55:56 PM (26 years ago)
Author:
Hans Schönemann <hannes@…>
Branches:
(u'spielwiese', '17f1d200f27c5bd38f5dfc6e8a0879242279d1d8')
Children:
e9a5b9f04c03846bd8c017cf227e7f9b1dc2e264
Parents:
1387fc63c740eb636ccead6aacbb9969235f1dfd
Message:
*** empty log message ***


git-svn-id: file:///usr/local/Singular/svn/trunk@1480 2c84dea3-7e68-4137-9b89-c4e89433aadc
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Singular/misc.cc

    r1387fc6 rdf595d  
    373373      extern FILE *yylpin;
    374374      lib_style_types lib_style; // = OLD_LIBSTYLE;
    375      
     375
    376376      yylpin = fp;
    377377      yylplex(str, libnamebuf, &lib_style, GET_INFO);
    378378      reinit_yylp();
    379       if(lib_style == OLD_LIBSTYLE) {
    380         char buf[256];
    381         fseek(fp, 0, SEEK_SET);
     379      if(lib_style == OLD_LIBSTYLE)
     380      {
     381        char buf[256];
     382        fseek(fp, 0, SEEK_SET);
    382383#else /* HAVE_LIBPARSER */
    383         { char buf[256];
     384        { char buf[256];
    384385#endif /* HAVE_LIBPARSER */
    385         Warn( "library %s has an old format. Please fix it for the next time",
    386               str);
    387         BOOLEAN found=FALSE;
    388         while (fgets( buf, sizeof(buf), fp))
    389           {
    390             if (strncmp(buf,"//",2)==0)
    391               {
    392                 if (found) return;
    393               }
    394             else if ((strncmp(buf,"proc ",5)==0)||(strncmp(buf,"LIB ",4)==0))
    395               {
    396                 if (!found) Warn("no help part in library found");
    397                 return;
    398               }
    399             else
    400               {
    401                 found=TRUE;
    402                 PrintS(buf);
    403               }
    404           }
     386        Warn( "library %s has an old format. Please fix it for the next time",
     387              str);
     388        BOOLEAN found=FALSE;
     389        while (fgets( buf, sizeof(buf), fp))
     390        {
     391          if (strncmp(buf,"//",2)==0)
     392          {
     393            if (found) return;
     394          }
     395          else if ((strncmp(buf,"proc ",5)==0)||(strncmp(buf,"LIB ",4)==0))
     396          {
     397            if (!found) Warn("no help part in library found");
     398            return;
     399          }
     400          else
     401          {
     402            found=TRUE;
     403            PrintS(buf);
     404          }
     405        }
    405406      }
    406407#ifdef HAVE_LIBPARSER
    407       else {
    408         fclose( yylpin );
    409         PrintS(text_buffer);
    410         FreeL(text_buffer);
     408      else
     409      {
     410        fclose( yylpin );
     411        PrintS(text_buffer);
     412        FreeL(text_buffer);
    411413      }
    412414#endif /* HAVE_LIBPARSER */
Note: See TracChangeset for help on using the changeset viewer.