From: Matthias Schwarzott Date: Thu, 26 Jul 2007 11:04:13 +0000 (+0200) Subject: fix inotify to work not only once X-Git-Tag: 174~1874 X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=commitdiff_plain;h=f4dce170d5eb4b798b4ca6c8480f10cacbc7d72c fix inotify to work not only once --- diff --git a/udevd.c b/udevd.c index 69572c626..8f56de6ff 100644 --- a/udevd.c +++ b/udevd.c @@ -1202,7 +1202,7 @@ int main(int argc, char *argv[], char *envp[]) reload_config = 1; buf = malloc(nbytes); - if (buf != NULL) { + if (buf == NULL) { err("error getting buffer for inotify, disable watching"); close(inotify_fd); inotify_fd = -1;