diffs for mawk0.995

Mike Brennan brennan at ssc-vax.UUCP
Tue Jun 25 02:36:50 AEST 1991


Enclosed are two patches for mawk0.995
One is only for DOS.
The other is only for ansi compilers with signed chars

Mike Brennan
brennan at bcsaic.boeing.com

----------------cut here---------------------------
# This is a shell archive.  Remove anything before this line,
# then unpack it by saving it in a file and typing "sh file".
#
# Wrapped by mlssun6!brennan on Mon Jun 24 09:29:04 PDT 1991
# Contents:  init.c.diff scan.c.diff
 
echo x - init.c.diff
sed 's/^@//' > "init.c.diff" <<'@//E*O*F init.c.diff//'
*** init.c.old
--- init.c	Wed Jun 19 10:23:41 1991
***************
*** 15,20 ****
--- 15,23 ----
  
  
  /* $Log:	init.c,v $
+  * Revision 3.2  91/06/19  10:23:41  brennan
+  * changes for xenix_r2, call this version 0.997
+  * 
   * Revision 3.1  91/06/07  10:27:38  brennan
   * VERSION 0.995
   * 
***************
*** 224,230 ****
  #if  MSDOS  &&  ! HAVE_REARGV
  
  static void  emit_prompt()
! {  static char prompt[] = DOS_PROMPT ;
     int fd = open("CON", O_WRONLY, 0) ;
  
     (void) write(fd, prompt, strlen(prompt)) ;
--- 227,233 ----
  #if  MSDOS  &&  ! HAVE_REARGV
  
  static void  emit_prompt()
! {  static char prompt[] = "mawk> " ;
     int fd = open("CON", O_WRONLY, 0) ;
  
     (void) write(fd, prompt, strlen(prompt)) ;
@//E*O*F init.c.diff//
chmod u=rw,g=r,o=r init.c.diff
 
echo x - scan.c.diff
sed 's/^@//' > "scan.c.diff" <<'@//E*O*F scan.c.diff//'
*** scan.c.old
--- scan.c.new
***************
*** 15,20 ****
--- 15,23 ----
  
  
  /* $Log:	scan.c,v $
+  * Revision 3.2  91/06/15  09:05:16  brennan
+  * some casting of [unsigned] char* to make gcc happy
+  * 
   * Revision 3.1  91/06/07  10:28:15  brennan
   * VERSION 0.995
   * 
***************
*** 104,110 ****
  
      buffp = buffer = (unsigned char *) zmalloc( BUFFSZ+1 ) ;
  
!     eof_flag = fillbuff(program_fd, buffer, BUFFSZ) < BUFFSZ ;
    }
  }
  
--- 107,113 ----
  
      buffp = buffer = (unsigned char *) zmalloc( BUFFSZ+1 ) ;
  
!     eof_flag = fillbuff(program_fd, (char *) buffer, BUFFSZ) < BUFFSZ ;
    }
  }
  
***************
*** 166,172 ****
    if ( *buffp == 0  )
        if ( !eof_flag ) 
        { buffp = buffer ;
!         eof_flag = fillbuff(program_fd, buffer,BUFFSZ) < BUFFSZ ;
        }
  
    return *buffp++ ; /* note can un_next() , eof which is zero */
--- 169,175 ----
    if ( *buffp == 0  )
        if ( !eof_flag ) 
        { buffp = buffer ;
!         eof_flag = fillbuff(program_fd, (char *)buffer,BUFFSZ) < BUFFSZ ;
        }
  
    return *buffp++ ; /* note can un_next() , eof which is zero */
***************
*** 636,643 ****
     moving a pointer forward by reference */
  
  static int  hex( start_p )
!   unsigned char **start_p ;
! { register unsigned char *p = *start_p ;
    register unsigned x ;
    unsigned t ;
  
--- 639,646 ----
     moving a pointer forward by reference */
  
  static int  hex( start_p )
!   char **start_p ;
! { register unsigned char *p = (unsigned char*) *start_p ;
    register unsigned x ;
    unsigned t ;
  
***************
*** 651,657 ****
    if ( 'A' <= *p && *p <= 'f' && (t = hex_value(*p)) )
    { x = (x<<4) + t ; p++ ; }
  
!   *start_p = p ;
    return x ;
  }
  
--- 654,660 ----
    if ( 'A' <= *p && *p <= 'f' && (t = hex_value(*p)) )
    { x = (x<<4) + t ; p++ ; }
  
!   *start_p = (char *) p ;
    return x ;
  }
  
@//E*O*F scan.c.diff//
chmod u=rw,g=r,o=r scan.c.diff
 
exit 0



More information about the Alt.sources mailing list