ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/include/dynbuf.h
(Generate patch)

Comparing deliantra/server/include/dynbuf.h (file contents):
Revision 1.2 by root, Tue Sep 19 10:35:21 2006 UTC vs.
Revision 1.3 by root, Tue Sep 19 22:05:55 2006 UTC

66 memcpy (alloc (len), p, len); 66 memcpy (alloc (len), p, len);
67 } 67 }
68 68
69 void add (char c) 69 void add (char c)
70 { 70 {
71 if (room < 1) 71 alloc (1)[0] = c;
72 _reserve (1);
73
74 room--;
75 *ptr++ = c;
76 } 72 }
77 73
78 void add (const char *s) 74 void add (const char *s)
79 { 75 {
80 add (s, strlen (s)); 76 add (s, strlen (s));

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines