Index: uspace/lib/posix/fcntl.h
===================================================================
--- uspace/lib/posix/fcntl.h	(revision eca52a800f89d716e768d8312dbea7309e514476)
+++ uspace/lib/posix/fcntl.h	(revision 6817eba10030a28743541ff86eeb296a080b9f74)
@@ -38,4 +38,5 @@
 #include "sys/types.h"
 #include "libc/fcntl.h"
+#include "errno.h"
 
 /* Mask for file access modes. */
@@ -72,7 +73,7 @@
 
 #undef open
-#define open(path, oflag, ...) \
+#define open(path, ...) \
 	({ \
-		int rc = open(path, oflag, ##__VA_ARGS__); \
+		int rc = open(path, ##__VA_ARGS__); \
 		if (rc < 0) { \
 			errno = -rc; \
