Skip to contentSkip to conversation

loader: document that errno is set

PATCH In review Michael S. Tsirkin 2 participants 3 messages Feb 5, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 loader: document that errno is set

Document that get_image_size sets errorno
on failure.

---
 include/hw/loader.h | 7 +++++++
 1 file changed, 7 insertions(+)
include/hw/loader.h +7 -0
index 7a23d6b..91b0122 100644
@@ -4,6 +4,13 @@
 #include "hw/nvram/fw_cfg.h"
 
 /* loader.c */
+/**
+ * get_image_size: retrieve size of an image file
+ * @filename: Path to the image file
+ *
+ * Returns the size of the image file on success, -1 otherwise.
+ * On error, errno is also set as appropriate.
+ */
 int get_image_size(const char *filename);
 int load_image(const char *filename, uint8_t *addr); /* deprecated */
 int load_image_targphys(const char *filename, hwaddr,
Signature · 1 line
MST
Reviewed-by on v1 1/1
#1 lore raw
Quoted 1 line · Michael S. Tsirkin

Document that get_image_size sets errorno

s/errorno/errno/

Quoted 8 lines

on failure.

---
 include/hw/loader.h | 7 +++++++
 1 file changed, 7 insertions(+)
Signature · 2 lines
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org
#2 lore raw
Quoted 7 lines · Eric Blake
Quoted 1 line · Michael S. Tsirkin

Document that get_image_size sets errorno

s/errorno/errno/

Quoted 2 lines

on failure.

Quoted 8 lines
Quoted 6 lines
---
 include/hw/loader.h | 7 +++++++
 1 file changed, 7 insertions(+)

Fixed in my tree, I won't repost just for this though.

Quoted 4 lines
Signature · 2 lines
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org