From: Scott James Remnant Date: Mon, 23 Feb 2009 18:33:49 +0000 (+0000) Subject: Look at more inotify events in the buffer than just the first. X-Git-Tag: 174~1154 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=commitdiff_plain;h=80be8c48c59708c52993ceddeedef8c2ed417016;ds=sidebyside Look at more inotify events in the buffer than just the first. --- diff --git a/udev/udevd.c b/udev/udevd.c index 5598628a5..cfc091b69 100644 --- a/udev/udevd.c +++ b/udev/udevd.c @@ -546,9 +546,10 @@ static int handle_inotify(struct udev *udev) read(inotify_fd, buf, nbytes); - for (pos = 0, ev = (struct inotify_event *)(buf + pos); pos < nbytes; pos += sizeof(struct inotify_event) + ev->len) { + for (pos = 0; pos < nbytes; pos += sizeof(struct inotify_event) + ev->len) { struct udev_device *dev; + ev = (struct inotify_event *)(buf + pos); if (ev->len) { dbg(udev, "inotify event: %x for %s\n", ev->mask, ev->name); reload_config = 1;