home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c005 / 5.ddi / C / WNERROR.C < prev    next >
Encoding:
C/C++ Source or Header  |  1986-08-05  |  1.1 KB  |  41 lines

  1. /**
  2. *
  3. * Name        wnerror -- React to window system error.
  4. *
  5. * Synopsis    error = wnerror(ercode);
  6. *
  7. *        int error      Returned value of ercode.
  8. *        int ercode      Code denoting type of error
  9. *                  (WN_NO_ERROR if no error).
  10. *
  11. * Description    This function sets the global C TOOLS PLUS window error
  12. *        indicator (b_wnerr, declared in BWINDOW.H, defined in
  13. *        WNCREATE.C) to a given value.
  14. *
  15. *        Alternatively, this function is available as a macro
  16. *        which is defined in BWINDOW.H when symbol WN_EXT_ERROR
  17. *        is zero.  Compile the window routines with the macro
  18. *        version to save code space.  Compile with calls to this
  19. *        external version to catch errors (via a breakpoint) as
  20. *        they happen.
  21. *
  22. * Returns    error          Returned value of ercode.
  23. *        ercode          Code denoting type of error
  24. *                  (WN_NO_ERROR if no error).
  25. *
  26. * Version    3.0  (C)Copyright Blaise Computing Inc. 1986
  27. *
  28. **/
  29.  
  30. #include <bwindow.h>
  31.  
  32. #if WN_EXT_ERROR == 0
  33. #undef wnerror                  /* Un-define macro version.     */
  34. #endif
  35.  
  36. int wnerror(ercode)
  37. int ercode;
  38. {
  39.     return b_wnerr = ercode;
  40. }
  41.