home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / cproto.zip / cproto46 / trace.h < prev    next >
C/C++ Source or Header  |  1998-01-18  |  594b  |  26 lines

  1. /* $Id: trace.h,v 4.2 1998/01/19 00:49:35 cthuang Exp $ */
  2.  
  3. #ifndef TRACE_H
  4. #define TRACE_H
  5.  
  6. #if !defined(__GNUC__) && !defined(__attribute__)
  7. #define __attribute__(p)
  8. #endif
  9.  
  10. extern void Trace(char *f, ...) __attribute__((format (printf,1,2)));
  11. extern void show_alloc(void);
  12. extern void Elapsed(char *msg);
  13. extern void WalkBack(void);
  14. extern void fail_alloc(char *msg, char *ptr);
  15.  
  16. #ifdef DOALLOC
  17. extern void *doalloc(void *,unsigned);
  18. extern void dofree(void *);
  19.  
  20. #define malloc(n)    doalloc(0,n)
  21. #define realloc(p,n) doalloc(p,n)
  22. #define free(n)      dofree(n)
  23. #endif
  24.  
  25. #endif /* TRACE_H */
  26.