pa1285@sdcc13.ucsd.edu (David L. Brown) (01/05/90)
I have found the (at least one) problem with signal(2). It seems that when lib.h was translated to posix/ansi the declaration of begsig changed from a function to a pointer to a function. Whenever signal was called, and was generated, the CPU would jump to the address pointed to by the first two bytes of the function, not to the function itself. To fix: Apply the patch below to lib.h. Recompile ansi/signal.c and update libc.a with the new signal.s. Recompile any commands that use signal (ar, cc, and many more, use fgrep). This should fix problems with the c compiler either not stopping, or crashing the entire system. David L. Brown dbrown@ucsd.edu --- cut here --- *** old/lib.h Thu Jan 4 10:22:00 1990 --- lib.h Thu Jan 4 10:22:51 1990 *************** *** 35,40 **** _PROTOTYPE( void panic, (const char *message, int errnum) ); _PROTOTYPE( int sendrec, (int src_dest, message *m_ptr) ); _PROTOTYPE( int syserr, (const char *name) /* used but not defined */ ); ! extern _PROTOTYPE( void (*begsig), (int dummy) ); #endif /* _LIB_H */ --- 35,40 ---- _PROTOTYPE( void panic, (const char *message, int errnum) ); _PROTOTYPE( int sendrec, (int src_dest, message *m_ptr) ); _PROTOTYPE( int syserr, (const char *name) /* used but not defined */ ); ! extern _PROTOTYPE( void *begsig, (int dummy) ); #endif /* _LIB_H */ ===============