From f412fc9ffa67888a772c6b8c6a96ebad8a47a373 Mon Sep 17 00:00:00 2001 From: Peter Krempa Date: Tue, 1 Jul 2014 16:54:11 +0200 Subject: [PATCH] storage: gluster: Fix header reader function Advance the right pointer to actually append to the buffer. We were lucky that all reads were completed in one try. --- src/storage/storage_backend_gluster.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/storage/storage_backend_gluster.c b/src/storage/storage_backend_gluster.c index cab23b06f5..1a2b4ec5a3 100644 --- a/src/storage/storage_backend_gluster.c +++ b/src/storage/storage_backend_gluster.c @@ -173,7 +173,7 @@ virStorageBackendGlusterReadHeader(glfs_fd_t *fd, } if (r == 0) return nread; - buf += r; + s += r; maxlen -= r; nread += r; } -- GitLab