projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
affda78
)
util: flush inotify fd only when we have it
author
Lennart Poettering
<lennart@poettering.net>
Fri, 14 May 2010 02:36:47 +0000
(
04:36
+0200)
committer
Lennart Poettering
<lennart@poettering.net>
Fri, 14 May 2010 02:36:47 +0000
(
04:36
+0200)
util.c
patch
|
blob
|
history
diff --git
a/util.c
b/util.c
index
f5f1b3a
..
f8b3f44
100644
(file)
--- a/
util.c
+++ b/
util.c
@@
-1627,8
+1627,9
@@
int acquire_terminal(const char *name, bool fail, bool force) {
}
for (;;) {
- if ((r = flush_fd(notify)) < 0)
- goto fail;
+ if (notify >= 0)
+ if ((r = flush_fd(notify)) < 0)
+ goto fail;
/* We pass here O_NOCTTY only so that we can check the return
* value TIOCSCTTY and have a reliable way to figure out if we