--------------------- PatchSet 988 Date: 2000/12/22 12:50:18 Author: nikitadanilov Branch: raid Tag: (none) Log: Added propotypes for initCommCio2() and abend.c functions Members: src/protos.h:1.6.4.1.2.1.2.1.2.1->1.6.4.1.2.1.2.1.2.2 Index: squid/src/protos.h =================================================================== RCS file: /cvsroot/squid-sf//squid/src/protos.h,v retrieving revision 1.6.4.1.2.1.2.1.2.1 retrieving revision 1.6.4.1.2.1.2.1.2.2 diff -u -r1.6.4.1.2.1.2.1.2.1 -r1.6.4.1.2.1.2.1.2.2 --- squid/src/protos.h 17 Dec 2000 14:36:24 -0000 1.6.4.1.2.1.2.1.2.1 +++ squid/src/protos.h 22 Dec 2000 12:50:18 -0000 1.6.4.1.2.1.2.1.2.2 @@ -1,6 +1,6 @@ /* - * $Id: protos.h,v 1.6.4.1.2.1.2.1.2.1 2000/12/17 14:36:24 hno Exp $ + * $Id: protos.h,v 1.6.4.1.2.1.2.1.2.2 2000/12/22 12:50:18 nikitadanilov Exp $ * * * SQUID Internet Object Cache http://squid.nlanr.net/Squid/ @@ -1259,6 +1259,7 @@ extern int commCioLoop(); extern int cioCatchLostIO(); extern int initCommCio(); +extern int initCommCio2(); extern void clearLostIOBitmap( int fd ); extern void setLostIOBitmap( int fd ); #endif @@ -1281,3 +1282,31 @@ #if URL_CHECKSUM_DEBUG extern unsigned int url_checksum(const char *url); #endif + +/* + * abend.c + */ +/** initialises abend sub-system. Should be called from main directly + (that is, not from function called from main. */ +void abendInit( int argc, char **argv ); + +/** prints current stack trace to the debug( 92, 2 ). Tries to resolve + address to symbol name either through bfd interfaces or through + dlsym. If you see spurious `sigaction' in backtrace, read it as + __restore() --- function call inserted into stack by kernel when + vectoring control to the signal handler. Problem is that __restore + is not exported by libc. */ +void printBacktrace(); + +/** abnormal end. Prints backtrace them either dumps core into + specified directory (/tmp by default --- XXX Unixism) or tries to + attach debugger or _exits */ +void abend(); + +/** resolves address to the symbol name. + If exactAddress is not NULL, address of the beginning of the + symbol in question returned there. */ +const char *getNameByAddress( void *address, void **exactAddress ); + +/** resolves symbol name to the address */ +void *getAddressFor( char *name );