[gforth] / gforth / Attic / main.c  

gforth: gforth/Attic/main.c

Diff for /gforth/Attic/main.c between version 1.40 and 1.41

version 1.40, Tue Sep 24 19:15:04 1996 UTC version 1.41, Mon Sep 30 13:16:12 1996 UTC
Line 39 
Line 39 
 jmp_buf throw_jmp_buf;  jmp_buf throw_jmp_buf;
 #endif  #endif
   
 #ifndef FUZZ  
 #  define FUZZ 0x4000  
 #endif  
   
 #ifndef DEFAULTPATH  #ifndef DEFAULTPATH
 #  define DEFAULTPATH "/usr/local/lib/gforth:."  #  define DEFAULTPATH "/usr/local/lib/gforth:."
 #endif  #endif
Line 169 
Line 165 
   Cell preamblesize=0;    Cell preamblesize=0;
   Label *symbols=engine(0,0,0,0,0);    Label *symbols=engine(0,0,0,0,0);
   UCell check_sum=checksum(symbols);    UCell check_sum=checksum(symbols);
   Cell fuzz=FUZZ; /* 16 k fuzz to move fixed size images around */  
   
   static char* endianstring[]= { "big","little" };    static char* endianstring[]= { "big","little" };
   
Line 225 
Line 220 
   
   wholesize = preamblesize+dictsize+dsize+rsize+fsize+lsize;    wholesize = preamblesize+dictsize+dsize+rsize+fsize+lsize;
   imagesize = preamblesize+header.image_size+((header.image_size-1)/sizeof(Cell))/8+1;    imagesize = preamblesize+header.image_size+((header.image_size-1)/sizeof(Cell))/8+1;
   image=malloc((wholesize>imagesize?wholesize:imagesize)+fuzz);    image=malloc((wholesize>imagesize?wholesize:imagesize)/*+sizeof(Float)*/);
   /*image = maxaligned(image);*/    /*image = maxaligned(image);*/
 /*  memset(image,0,wholesize); */ /* why? - anton */    memset(image,0,wholesize); /* why? - anton */
   
   if(header.base==0) image += fuzz/2;  
   else if((UCell)(header.base - (Cell)image + preamblesize) < fuzz)  
     image = header.base - preamblesize;  
   
   rewind(imagefile);  /* fseek(imagefile,0L,SEEK_SET); */    rewind(imagefile);  /* fseek(imagefile,0L,SEEK_SET); */
   fread(image,1,imagesize,imagefile);    fread(image,1,imagesize,imagefile);
   fclose(imagefile);    fclose(imagefile);
Line 338 
Line 328 
   
   progname = argv[0];    progname = argv[0];
   if ((path=getenv("GFORTHPATH"))==NULL)    if ((path=getenv("GFORTHPATH"))==NULL)
     path = strcpy(malloc(strlen(DEFAULTPATH)+1),DEFAULTPATH);      path = DEFAULTPATH;
   opterr=0;    opterr=0;
   while (1) {    while (1) {
     int option_index=0;      int option_index=0;


Generate output suitable for use with a patch program
Legend:
Removed from v.1.40  
changed lines
  Added in v.1.41

CVS Admin

Powered by ViewCVS 1.0-dev
(Powered by ViewCVS)

ViewCVS and CVS Help