chiark
/
gitweb
/
~mdw
/
disorder
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
missing EXTRA_DIST and path
[disorder]
/
lib
/
syscalls.c
diff --git
a/lib/syscalls.c
b/lib/syscalls.c
index a84e2eb763f3dee1d1094388d268a826f60db9cd..f05b644c37f825daf6a77c0ff895878c0015ed17 100644
(file)
--- a/
lib/syscalls.c
+++ b/
lib/syscalls.c
@@
-66,6
+66,13
@@
void nonblock(int fd) {
fcntl(fd, F_GETFL)) | O_NONBLOCK));
}
fcntl(fd, F_GETFL)) | O_NONBLOCK));
}
+void blocking(int fd) {
+ mustnotbeminus1("fcntl F_SETFL",
+ fcntl(fd, F_SETFL,
+ mustnotbeminus1("fcntl F_GETFL",
+ fcntl(fd, F_GETFL)) & ~O_NONBLOCK));
+}
+
void cloexec(int fd) {
mustnotbeminus1("fcntl F_SETFD",
fcntl(fd, F_SETFD,
void cloexec(int fd) {
mustnotbeminus1("fcntl F_SETFD",
fcntl(fd, F_SETFD,