home *** CD-ROM | disk | FTP | other *** search
/ What PC? 1996 April / WHAT_PC_APR_96.ISO / internet / twinsock / src / packet.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-01-21  |  724 b   |  35 lines

  1. /*
  2.  *  TwinSock - "Troy's Windows Sockets"
  3.  *
  4.  *  Copyright (C) 1994  Troy Rollo <troy@cbme.unsw.EDU.AU>
  5.  *
  6.  *  This program is free software; you can redistribute it and/or modify
  7.  *  it under the terms of the license in the file LICENSE.TXT included
  8.  *  with the TwinSock distribution.
  9.  *
  10.  *  This program is distributed in the hope that it will be useful,
  11.  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
  12.  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 
  13.  */
  14.  
  15. enum packet_type
  16. {
  17.     PT_Data,
  18.     PT_Ack,
  19.     PT_Nak,
  20.     PT_Shutdown
  21. };
  22.  
  23. #define    PACKET_MAX 512
  24.  
  25. struct    packet
  26. {
  27.     short    iPacketID;
  28.     short    iPacketLen;
  29.     short    nCRC;
  30.     short    nType;
  31.     char    achData[PACKET_MAX];
  32. };
  33.  
  34.  
  35.