Skip to contentSkip to conversation

posix_fallocate.3: EBADF possible when lacking read access

PATCH New Martin Pärtel 1 participant 1 message Oct 8, 2012 Man-pages: manual pages for Linux -- Sections 2, 3, 4, 5, and 7

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 posix_fallocate.3: EBADF possible when lacking read access

posix_fallocate on a write-only FD may fail with a EBADF when fallocate(2) is unsupported by the filesystem and glibc must emulate it. The emulation requires read-write access to the file. The source code is in glibc's sysdeps/posix/posix_fallocate.c

Applies to git master.

man3/posix_fallocate.3 +2 -1
index 6fae367..b92c140 100644
@@ -71,7 +71,8 @@ is not set.
 .TP
 .B EBADF
 .I fd
-is not a valid file descriptor, or is not opened for writing.
+is not a valid file descriptor, or is not opened for
+both reading and writing.
 .TP
 .B EFBIG
 .I offset+len

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html