summaryrefslogtreecommitdiff
path: root/qemu-common.h
diff options
context:
space:
mode:
authorJuan Quintela <quintela@redhat.com>2009-07-27 16:13:22 +0200
committerAnthony Liguori <aliguori@us.ibm.com>2009-07-27 14:10:36 -0500
commit2880bc32b84831032d561f850b13b9f4f03d910e (patch)
tree3a46d47f2b1a992a95f8f2b28db57c855a751a47 /qemu-common.h
parent5647eb7475d0278e1a2a9198d7e146936b9d84b1 (diff)
define ENOTSUP the same that the other errors
aliguori: ENOTSUP is not 4096 universally, only on OpenBSD Signed-off-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'qemu-common.h')
-rw-r--r--qemu-common.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/qemu-common.h b/qemu-common.h
index 3cf7f4ed6c..5d7ffebcd7 100644
--- a/qemu-common.h
+++ b/qemu-common.h
@@ -38,6 +38,9 @@
#ifndef ENOMEDIUM
#define ENOMEDIUM ENODEV
#endif
+#if !defined(ENOTSUP) && defined(__OpenBSD__)
+#define ENOTSUP 4096
+#endif
#ifndef CONFIG_IOVEC
#define CONFIG_IOVEC
@@ -52,11 +55,9 @@ struct iovec {
#ifdef _WIN32
#define fsync _commit
#define lseek _lseeki64
-#define ENOTSUP 4096
extern int qemu_ftruncate64(int, int64_t);
#define ftruncate qemu_ftruncate64
-
static inline char *realpath(const char *path, char *resolved_path)
{
_fullpath(resolved_path, path, _MAX_PATH);