summaryrefslogtreecommitdiff
path: root/include/migration/qemu-file.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/migration/qemu-file.h')
-rw-r--r--include/migration/qemu-file.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/migration/qemu-file.h b/include/migration/qemu-file.h
index ea49f33fac..e1e2babcf5 100644
--- a/include/migration/qemu-file.h
+++ b/include/migration/qemu-file.h
@@ -31,15 +31,15 @@
* The pos argument can be ignored if the file is only being used for
* streaming. The handler should try to write all of the data it can.
*/
-typedef int (QEMUFilePutBufferFunc)(void *opaque, const uint8_t *buf,
- int64_t pos, int size);
+typedef ssize_t (QEMUFilePutBufferFunc)(void *opaque, const uint8_t *buf,
+ int64_t pos, size_t size);
/* Read a chunk of data from a file at the given position. The pos argument
* can be ignored if the file is only be used for streaming. The number of
* bytes actually read should be returned.
*/
-typedef int (QEMUFileGetBufferFunc)(void *opaque, uint8_t *buf,
- int64_t pos, int size);
+typedef ssize_t (QEMUFileGetBufferFunc)(void *opaque, uint8_t *buf,
+ int64_t pos, size_t size);
/* Close a file
*