/* * $Id: //devel/tools/main/backstealth/bsdefs.h#1 $ * * written by: Stephen J. Friedl * Software Consultant * Tustin, California USA * steve@unixwiz.net * * Common definitions that are shared by multiple programs. We * insure that all of our programs #include this before all the * other *local* #includes. */ /*------------------------------------------------------------------------ * Given an array, return the number of *items* - not *bytes* - in it */ #define ASIZE(t) (int) (sizeof(t) / sizeof((t)[0])) /*------------------------------------------------------------------------ * mark the variables as explicitly unused so lint (or the compiler) won't * complain about them. */ #define UNUSED_PARAMETER(p) (void)(p) #define UNUSED_VARIABLE(p) (void)(p) extern "C" { extern BOOL __stdcall enable_priv(const char *privname); /*lint -sem(dieA, r_no) */ /*lint -sem(dieW, r_no) */ /*lint -printf(1, dieA) */ /*lint -wprintf(1, dieW) */ extern void __cdecl dieA(const char *format, ...); extern void __cdecl dieW(const wchar_t *format, ...); /*lint -printf(1, odprintfA) */ /*lint -wprintf(1, odprintW) */ extern void __cdecl odprintfA(const char *format, ...); extern void __cdecl odprintfW(const wchar_t *format, ...); #ifdef _UNICODE # define odprintf odprintfW # define die dieW #else # define odprintf odprintfA # define die dieA #endif } // strip trailing whitespace extern char * __stdcall strip(char *); extern wchar_t * __stdcall strip(wchar_t *);