Make processes work on HP-UX
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
diff --git a/fio.c b/fio.c
index 8185481..a8608f4 100644
--- a/fio.c
+++ b/fio.c
@@ -1294,6 +1294,7 @@
struct thread_data *td;
void *data, *ret;
+#ifndef __hpux
data = shmat(shmid, NULL, 0);
if (data == (void *) -1) {
int __err = errno;
@@ -1301,6 +1302,12 @@
perror("shmat");
return __err;
}
+#else
+ /*
+ * HP-UX inherits shm mappings?
+ */
+ data = threads;
+#endif
td = data + offset * sizeof(struct thread_data);
ret = thread_main(td);