X-Git-Url: http://git.ipfire.org/?p=ipfire-2.x.git;a=blobdiff_plain;f=src%2Fpatches%2Fsamba%2Fsamba-3.2.5-inotify.patch;fp=src%2Fpatches%2Fsamba%2Fsamba-3.2.5-inotify.patch;h=0000000000000000000000000000000000000000;hp=e215f5bcc931b03c2d1335fb216e83d905ee093a;hb=1dd31d858ecc4d37fa9c895b59e2b752cc124818;hpb=b3e5529459d4dec78aa07b08b4ccfacdc449c3f9 diff --git a/src/patches/samba/samba-3.2.5-inotify.patch b/src/patches/samba/samba-3.2.5-inotify.patch deleted file mode 100644 index e215f5bcc9..0000000000 --- a/src/patches/samba/samba-3.2.5-inotify.patch +++ /dev/null @@ -1,49 +0,0 @@ -Index: samba-3.6.6/source3/smbd/notify_inotify.c -=================================================================== ---- samba-3.6.6.orig/source3/smbd/notify_inotify.c -+++ samba-3.6.6/source3/smbd/notify_inotify.c -@@ -77,6 +77,7 @@ struct inotify_private { - struct sys_notify_context *ctx; - int fd; - struct inotify_watch_context *watches; -+ bool broken_inotify; /* Late stop for broken system */ - }; - - struct inotify_watch_context { -@@ -241,8 +242,15 @@ static void inotify_handler(struct event - filenames, and thus can't know how much to allocate - otherwise - */ -- if (ioctl(in->fd, FIONREAD, &bufsize) != 0 || -- bufsize == 0) { -+ if ((ioctl(in->fd, FIONREAD, &bufsize) != 0) && (errno == EACCES)) { -+ /* -+ * Workaround for broken system (SELinux policy bug fixed since long but it is always better not to loop on EACCES) -+ */ -+ TALLOC_FREE(fde); -+ in->broken_inotify = True; -+ return; -+ } -+ if (bufsize == 0) { - DEBUG(0,("No data on inotify fd?!\n")); - TALLOC_FREE(fde); - return; -@@ -300,6 +308,7 @@ static NTSTATUS inotify_setup(struct sys - } - in->ctx = ctx; - in->watches = NULL; -+ in->broken_inotify = False; - - ctx->private_data = in; - talloc_set_destructor(in, inotify_destructor); -@@ -394,6 +403,10 @@ NTSTATUS inotify_watch(struct sys_notify - - in = talloc_get_type(ctx->private_data, struct inotify_private); - -+ if (in->broken_inotify) { -+ return NT_STATUS_OK; -+ } -+ - mask = inotify_map(e); - if (mask == 0) { - /* this filter can't be handled by inotify */