home *** CD-ROM | disk | FTP | other *** search
/ Network Support Encyclopedia 96-1 / novell-nsepro-1996-1-cd2.iso / download / netware / xsap1a.exe / COMMON.H < prev    next >
Text File  |  1994-09-14  |  3KB  |  76 lines

  1. /****************************************************************************
  2. **    File:    COMMON.H
  3. **
  4. **    Desc:
  5. **
  6. **        Definitions which are shared with both the client and server process.
  7. **
  8. **        Please note the Server SAP type number used in this sample code 
  9. **        [0x0275] must not be used in a production application; as that it 
  10. **        is registered to Novell Developer Support as a Sample Code server 
  11. **        SAP type.
  12. **
  13. **    Disclaimer:
  14. **
  15. **        Novell, Inc. makes no representations or warranties with respect to
  16. **        any NetWare software, and specifically disclaims any express or
  17. **        implied warranties of merchantability, title, or fitness for a
  18. **        particular purpose.  
  19. **
  20. **        Distribution of any NetWare software is forbidden without the
  21. **        express written consent of Novell, Inc.  Further, Novell reserves
  22. **        the right to discontinue distribution of any NetWare software.
  23. **
  24. **        Novell is not responsible for lost profits or revenue, loss of use
  25. **        of the software, loss of data, costs of re-creating lost data, the
  26. **        cost of any substitute equipment or program, or claims by any party
  27. **        other than you.  Novell strongly recommends a backup be made before
  28. **        any software is installed.   Technical support for this software
  29. **        may be provided at the discretion of Novell.
  30. **
  31. **
  32. **    Programmers:
  33. **
  34. **        Ini    Who                        Firm
  35. **        -----------------------------------------------------------------------
  36. **        ABJ    Adam B. Jerome            Novell Developer Support.
  37. **
  38. **    History:
  39. **
  40. **        When        Who    What
  41. **        -----------------------------------------------------------------------
  42. **        08-19-94    ABJ    First code.
  43. **        09-14-94 ABJ    I was brain-dead on the first release of this file;
  44. **                            sorry about that.  The COM_SERVER_TYPE was defined as 
  45. **                            0x9090 (the TDT test socket) when it should have been
  46. **                            defined as 0x0275 (the Novell Developer Support Test
  47. **                            server type).
  48. */
  49.  
  50. /****************************************************************************
  51. **    Define macros.
  52. */
  53. #define COM_SERVER_TYPE        0x0275    /* Novell Developer Support test server type */
  54. #define COM_MAX_DATA_SIZE    512        /* Maximum packet size        */
  55.  
  56. #define COM_REQ_PING                0
  57.  
  58. #define COM_SUCCESS                0
  59. #define COM_ERR_UNKNOWN_TYPE    (-1)
  60.  
  61. /****************************************************************************
  62. **    Structures.
  63. */
  64. #pragma pack(1)
  65.  
  66. typedef struct COM_DATA_PACKET
  67.     {
  68.     long     type;
  69.     short    status;
  70.     char    data[COM_MAX_DATA_SIZE - sizeof(long) - sizeof(short)];
  71.     } COM_DATA_PACKET;
  72.  
  73. #pragma pack()
  74.  
  75.  
  76.