Stop listening for inotify data when there's none
authorVolker Lendecke <vl@samba.org>
Sat, 27 Jun 2009 10:20:18 +0000 (12:20 +0200)
committerVolker Lendecke <vl@samba.org>
Sat, 27 Jun 2009 10:25:01 +0000 (12:25 +0200)
There have been some reports that we're flooding syslog with "No data on
inotify fd?!". I haven't been able to reproduce this yet. Until then, it is
better to just list this message once.

source3/smbd/notify_inotify.c

index a80927b830fa0458ec27f985ab2aa73ae1084f07..26570a22162d5facef1536216dec317934c7b326 100644 (file)
@@ -241,6 +241,7 @@ static void inotify_handler(struct event_context *ev, struct fd_event *fde,
        if (ioctl(in->fd, FIONREAD, &bufsize) != 0 || 
            bufsize == 0) {
                DEBUG(0,("No data on inotify fd?!\n"));
+               TALLOC_FREE(fde);
                return;
        }