Skip to content

Commit

Permalink
Fix compile problems on win32
Browse files Browse the repository at this point in the history
Change-Id: I597f6fea9a4b943ba8c7a28d0eaa4cff22fe7c01
Reviewed-on: http://review.couchbase.org/11084
Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
Tested-by: Trond Norbye <trond.norbye@gmail.com>
  • Loading branch information
trondn committed Nov 22, 2011
1 parent f629b7a commit cc98226
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
1 change: 1 addition & 0 deletions include/libcouchbase/couchbase.h
Expand Up @@ -487,6 +487,7 @@ extern "C" {
* from this command
* @return Status of the operation.
*/
LIBCOUCHBASE_API
libcouchbase_error_t libcouchbase_flush(libcouchbase_t instance,
const void* cookie);

Expand Down
4 changes: 2 additions & 2 deletions src/instance.c
Expand Up @@ -281,9 +281,9 @@ static void libcouchbase_update_serverlist(libcouchbase_t instance)
*/
static bool parse_chunk(libcouchbase_t instance)
{
assert (instance->vbucket_stream.chunk_size != 0);

buffer_t *buffer = &instance->vbucket_stream.chunk;
assert(instance->vbucket_stream.chunk_size != 0);

if (instance->vbucket_stream.chunk_size == (size_t)-1) {
char *ptr = strstr(buffer->data, "\r\n");
long val;
Expand Down
3 changes: 2 additions & 1 deletion src/ringbuffer.c
Expand Up @@ -66,12 +66,13 @@ bool libcouchbase_ringbuffer_ensure_capacity(ringbuffer_t *buffer, size_t size)
return false;
} else {
// copy the data over :)
char *old;
size_t nbytes = buffer->nbytes;
size_t nr = libcouchbase_ringbuffer_read(buffer, new_root, nbytes);
if (nr != nbytes) {
abort();
}
char *old = buffer->root;
old = buffer->root;
buffer->size = new_size;
buffer->root = new_root;
buffer->nbytes = nbytes;
Expand Down

0 comments on commit cc98226

Please sign in to comment.