/[rdesktop]/sourceforge.net/trunk/rdesktop/parse.h
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /sourceforge.net/trunk/rdesktop/parse.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 432 by matthewc, Tue Jul 1 09:31:25 2003 UTC revision 1365 by jsorg71, Thu Jan 4 05:39:39 2007 UTC
# Line 1  Line 1 
1  /*  /*
2     rdesktop: A Remote Desktop Protocol client.     rdesktop: A Remote Desktop Protocol client.
3     Parsing primitives     Parsing primitives
4     Copyright (C) Matthew Chapman 1999-2002     Copyright (C) Matthew Chapman 1999-2007
5      
6     This program is free software; you can redistribute it and/or modify     This program is free software; you can redistribute it and/or modify
7     it under the terms of the GNU General Public License as published by     it under the terms of the GNU General Public License as published by
8     the Free Software Foundation; either version 2 of the License, or     the Free Software Foundation; either version 2 of the License, or
9     (at your option) any later version.     (at your option) any later version.
10      
11     This program is distributed in the hope that it will be useful,     This program is distributed in the hope that it will be useful,
12     but WITHOUT ANY WARRANTY; without even the implied warranty of     but WITHOUT ANY WARRANTY; without even the implied warranty of
13     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14     GNU General Public License for more details.     GNU General Public License for more details.
15      
16     You should have received a copy of the GNU General Public License     You should have received a copy of the GNU General Public License
17     along with this program; if not, write to the Free Software     along with this program; if not, write to the Free Software
18     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
# Line 70  typedef struct stream Line 70  typedef struct stream
70  #define out_uint32(s,v)         out_uint32_be(s,v)  #define out_uint32(s,v)         out_uint32_be(s,v)
71    
72  #else  #else
 #define next_be(s,v)            v = ((v) << 8) + *((s)->p++);  
73  #define in_uint16_be(s,v)       { v = *((s)->p++); next_be(s,v); }  #define in_uint16_be(s,v)       { v = *((s)->p++); next_be(s,v); }
74  #define in_uint32_be(s,v)       { in_uint16_be(s,v); next_be(s,v); next_be(s,v); }  #define in_uint32_be(s,v)       { in_uint16_be(s,v); next_be(s,v); next_be(s,v); }
75  #define out_uint16_be(s,v)      { *((s)->p++) = ((v) >> 8) & 0xff; *((s)->p++) = (v) & 0xff; }  #define out_uint16_be(s,v)      { *((s)->p++) = ((v) >> 8) & 0xff; *((s)->p++) = (v) & 0xff; }
# Line 92  typedef struct stream Line 91  typedef struct stream
91  #define out_uint8p(s,v,n)       { memcpy((s)->p,v,n); (s)->p += n; }  #define out_uint8p(s,v,n)       { memcpy((s)->p,v,n); (s)->p += n; }
92  #define out_uint8a(s,v,n)       out_uint8p(s,v,n);  #define out_uint8a(s,v,n)       out_uint8p(s,v,n);
93  #define out_uint8s(s,n)         { memset((s)->p,0,n); (s)->p += n; }  #define out_uint8s(s,n)         { memset((s)->p,0,n); (s)->p += n; }
94    
95    #define next_be(s,v)            v = ((v) << 8) + *((s)->p++);

Legend:
Removed from v.432  
changed lines
  Added in v.1365

  ViewVC Help
Powered by ViewVC 1.1.26