aboutsummaryrefslogtreecommitdiffstats
path: root/src/util.c
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2017-01-21 16:46:19 +0100
committerMattias Andrée <maandree@kth.se>2017-01-21 16:46:19 +0100
commitd1affdea923a0ac117ebb5e4c2e5011f59fd3188 (patch)
treee0f0f32ea6b57a0e2e496a2bb3280bb02eb0a13a /src/util.c
parentDon't open files from /dev/fd/, just return the fd. (diff)
downloadblind-d1affdea923a0ac117ebb5e4c2e5011f59fd3188.tar.gz
blind-d1affdea923a0ac117ebb5e4c2e5011f59fd3188.tar.bz2
blind-d1affdea923a0ac117ebb5e4c2e5011f59fd3188.tar.xz
Forgot a bang...
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--src/util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/util.c b/src/util.c
index 60e4cb0..6c1bd0a 100644
--- a/src/util.c
+++ b/src/util.c
@@ -227,7 +227,7 @@ int
xenopen(int status, const char *path, int flags, int mode, ...)
{
int fd;
- if (strncmp(path, "/dev/fd/", sizeof("/dev/fd/") - 1))
+ if (!strncmp(path, "/dev/fd/", sizeof("/dev/fd/") - 1))
if (!toi(path + sizeof("/dev/fd/") - 1, 0, INT_MAX, &fd))
return fd;
fd = open(path, flags, mode);