chiark / gitweb /
udev: dont use EWOULDBLOCK
authorDavid Herrmann <dh.herrmann@gmail.com>
Fri, 13 Mar 2015 12:41:55 +0000 (13:41 +0100)
committerDavid Herrmann <dh.herrmann@gmail.com>
Fri, 13 Mar 2015 13:09:55 +0000 (14:09 +0100)
EWOULDBLOCK is the same as EAGAIN, stop using it.

src/udev/udevd.c

index ac21d51..f7d6191 100644 (file)
@@ -291,7 +291,7 @@ static void worker_new(struct event *event) {
                                         fd_lock = open(udev_device_get_devnode(d), O_RDONLY|O_CLOEXEC|O_NOFOLLOW|O_NONBLOCK);
                                         if (fd_lock >= 0 && flock(fd_lock, LOCK_SH|LOCK_NB) < 0) {
                                                 log_debug_errno(errno, "Unable to flock(%s), skipping event handling: %m", udev_device_get_devnode(d));
-                                                err = -EWOULDBLOCK;
+                                                err = -EAGAIN;
                                                 fd_lock = safe_close(fd_lock);
                                                 goto skip;
                                         }