home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c065 / 2.ddi / CLIB2.ZIP / DBP.CPP < prev    next >
Encoding:
C/C++ Source or Header  |  1990-06-07  |  1.4 KB  |  34 lines

  1. /*-----------------------------------------------------------------------*
  2.  * filename - dbp.cpp
  3.  * Debugging output for streambuf
  4.  *-----------------------------------------------------------------------*/
  5.  
  6. /*[]------------------------------------------------------------[]*/
  7. /*|                                                              |*/
  8. /*|     Turbo C++ Run Time Library - Version 1.0                 |*/
  9. /*|                                                              |*/
  10. /*|                                                              |*/
  11. /*|     Copyright (c) 1990 by Borland International              |*/
  12. /*|     All Rights Reserved.                                     |*/
  13. /*|                                                              |*/
  14. /*[]------------------------------------------------------------[]*/
  15.  
  16. #include "filesys.h"
  17. #include <iostream.h>
  18. #include <stdio.h>    /* for sprintf */
  19. #include <string.h>
  20.  
  21. // debugging output for streambuf
  22. void streambuf::dbp()
  23. {
  24.     char s[80];
  25.     sprintf(s, "alloc_ = %d, unbuf_ = %d\n", alloc_, unbuf_);
  26.     write(F_stdout, s, strlen(s));
  27.     sprintf(s, "base_ = %p, ebuf_ = %p\n", base_, ebuf_);
  28.     write(F_stdout, s, strlen(s));
  29.     sprintf(s, "pbase_ = %p, pptr_ = %p, epptr_ = %p\n", pbase_, pptr_, epptr_);
  30.     write(F_stdout, s, strlen(s));
  31.     sprintf(s, "gptr_ = %p, egptr_ = %p, eback_ = %p\n", gptr_, egptr_, eback_);
  32.     write(F_stdout, s, strlen(s));
  33. }
  34.