aboutsummaryrefslogtreecommitdiffstats
path: root/com32/gplinclude/disk/write.h
diff options
context:
space:
mode:
authorPierre-Alexandre Meyer <pierre@mouraf.org>2009-04-21 09:56:11 -0700
committerPierre-Alexandre Meyer <pierre@mouraf.org>2009-04-21 09:56:11 -0700
commitbdeb4237ed17d2deab8ecf3cb95721047731cc3c (patch)
treeab4f653c7f7577fb951b2a8acbac6512733fb863 /com32/gplinclude/disk/write.h
parent731660cc2060f3bfdf5cd916bce1573985df6408 (diff)
downloadsyslinux-bdeb4237ed17d2deab8ecf3cb95721047731cc3c.tar.gz
syslinux-bdeb4237ed17d2deab8ecf3cb95721047731cc3c.tar.xz
syslinux-bdeb4237ed17d2deab8ecf3cb95721047731cc3c.zip
gpllib: Propagate error codes in disk library
It is worth propagating read/write error codes back to the caller. He can pass NULL to ignore them, or an int* that will be populated. To decode it, one can use the get_error function (see disk/error.c). Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Diffstat (limited to 'com32/gplinclude/disk/write.h')
-rw-r--r--com32/gplinclude/disk/write.h17
1 files changed, 10 insertions, 7 deletions
diff --git a/com32/gplinclude/disk/write.h b/com32/gplinclude/disk/write.h
index 89ca8736..be6494fa 100644
--- a/com32/gplinclude/disk/write.h
+++ b/com32/gplinclude/disk/write.h
@@ -1,11 +1,14 @@
#ifndef _WRITE_H_
#define _WRITE_H_
-int write_sectors(const struct driveinfo* drive_info, const unsigned int lba,
- const void *data, const int size);
+
+#include <disk/geom.h>
+
+int write_sectors(const struct driveinfo*, const unsigned int,
+ const void *, const int, int *);
int write_verify_sector(struct driveinfo* drive_info,
- const unsigned int lba,
- const void *data);
-int write_verify_sectors(struct driveinfo* drive_info,
- const unsigned int lba,
- const void *data, const int size);
+ const unsigned int,
+ const void *, int*);
+int write_verify_sectors(struct driveinfo*,
+ const unsigned int,
+ const void *, const int, int *);
#endif