cleanups
[util-vserver.git] / util-vserver / src / wrappers.h
index 90d598d..632be13 100644 (file)
@@ -34,6 +34,7 @@
 #include <sys/wait.h>
 #include <sys/stat.h>
 #include <sys/mount.h>
+#include <sys/ioctl.h>
 
 #define WRAPPER_DECL   UNUSED ALWAYSINLINE
 
@@ -265,6 +266,13 @@ Emkstemp(char *template)
   return res;
 }
 
+inline static WRAPPER_DECL void
+Eioctl(int fd, int request, void *p)
+{
+  int   res = ioctl(fd, request, p);
+  FatalErrnoError(res<0, "ioctl()");
+}
+
 #undef WRAPPER_DECL
 
 #endif //  H_UTIL_VSERVER_SRC_WRAPPERS_H