[dovecot-cvs] dovecot/src/lib buffer.c,1.14,1.15
cras at dovecot.org
cras at dovecot.org
Sat Jul 31 23:53:09 EEST 2004
Update of /home/cvs/dovecot/src/lib
In directory talvi:/tmp/cvs-serv24382
Modified Files:
buffer.c
Log Message:
buffer_append() fix
Index: buffer.c
===================================================================
RCS file: /home/cvs/dovecot/src/lib/buffer.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- buffer.c 31 Jul 2004 20:43:45 -0000 1.14
+++ buffer.c 31 Jul 2004 20:53:07 -0000 1.15
@@ -171,15 +171,9 @@
return data_size;
}
-size_t buffer_append(buffer_t *_buf, const void *data, size_t data_size)
+size_t buffer_append(buffer_t *buf, const void *data, size_t data_size)
{
- struct real_buffer *buf = (struct real_buffer *)_buf;
-
- if (!buffer_check_limits(buf, buf->used, &data_size, TRUE))
- return 0;
-
- memcpy(buf->w_buffer + buf->used, data, data_size);
- return data_size;
+ return buffer_write(buf, buf->used, data, data_size);
}
size_t buffer_append_c(buffer_t *buf, unsigned char chr)
More information about the dovecot-cvs
mailing list