diff options
author | Dr. David Alan Gilbert <dgilbert@redhat.com> | 2015-05-21 13:24:15 +0100 |
---|---|---|
committer | Juan Quintela <quintela@redhat.com> | 2015-06-12 06:54:01 +0200 |
commit | 7c1e52ba6f3994dc127118f491258ce84d0beb52 (patch) | |
tree | faebb08575cf114ca6e6d949673fb7e3a2892508 /include/migration | |
parent | bca7856ae8220d9f15ff0f44b97397529e26a552 (diff) |
Move copy out of qemu_peek_buffer
qemu_peek_buffer currently copies the data it reads into a buffer,
however a future patch wants access to the buffer without the copy,
hence rework to remove the copy to the layer above.
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Reviewed-by: Amit Shah <amit.shah@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Diffstat (limited to 'include/migration')
-rw-r--r-- | include/migration/qemu-file.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/migration/qemu-file.h b/include/migration/qemu-file.h index 318aa1ed07..4f67d79227 100644 --- a/include/migration/qemu-file.h +++ b/include/migration/qemu-file.h @@ -157,7 +157,7 @@ static inline void qemu_put_ubyte(QEMUFile *f, unsigned int v) void qemu_put_be16(QEMUFile *f, unsigned int v); void qemu_put_be32(QEMUFile *f, unsigned int v); void qemu_put_be64(QEMUFile *f, uint64_t v); -int qemu_peek_buffer(QEMUFile *f, uint8_t *buf, int size, size_t offset); +int qemu_peek_buffer(QEMUFile *f, uint8_t **buf, int size, size_t offset); int qemu_get_buffer(QEMUFile *f, uint8_t *buf, int size); ssize_t qemu_put_compression_data(QEMUFile *f, const uint8_t *p, size_t size, int level); |