Fix compile on older systems that don't have fallocate() on Linux
[fio.git] / helpers.c
index 1b6dea8e19b684862233a9814c82e9f299fb71c9..95625672b3417f0146e2f0c492a93ac4d54c54c0 100644 (file)
--- a/helpers.c
+++ b/helpers.c
@@ -9,6 +9,12 @@
 #include "arch/arch.h"
 #include "os/os.h"
 
+int _weak fallocate(int fd, int mode, off_t offset, off_t len)
+{
+       errno = ENOSYS;
+       return -1;
+}
+
 #ifndef __NR_fallocate
 int _weak posix_fallocate(int fd, off_t offset, off_t len)
 {