Pol  Revision:cb584c9
xbuffer.h
Go to the documentation of this file.
1 
7 #ifndef __XBUFFER_H
8 #define __XBUFFER_H
9 
10 // Note on XmitBuffer: generally, 'lenleft' will start out as the number of data bytes,
11 // and 'nsent' will start as 0. As more data is sent, nsent will move to the original lenleft,
12 // while lenleft will move to 0.
13 // Also note that malloc/free are used to allocate this structure, since
14 // data[] will be followed by (lenleft-1) more bytes, to house the data.
15 namespace Pol
16 {
17 namespace Core
18 {
19 struct XmitBuffer
20 {
22  unsigned short nsent; // how many bytes sent already
23  unsigned short lenleft; // how many bytes left to send
24  unsigned char data[1];
25 };
26 }
27 }
28 #endif
unsigned char data[1]
Definition: xbuffer.h:24
XmitBuffer * next
Definition: xbuffer.h:21
unsigned short lenleft
Definition: xbuffer.h:23
Definition: berror.cpp:12
unsigned short nsent
Definition: xbuffer.h:22