[Bug 14967] gnome menu is missing items
bugzilla-daemon at bugzilla.ubuntu.com
bugzilla-daemon at bugzilla.ubuntu.com
Wed Sep 21 14:09:06 UTC 2005
Please do not reply to this email. You can add comments at
http://bugzilla.ubuntu.com/show_bug.cgi?id=14967
Ubuntu | linux
------- Additional Comments From ttb at tentacle.dhs.org 2005-09-21 15:09 UTC -------
Here is another patch, that should work for all filesystems in the kernel tree.
I have heard that it might not work properly on ocfs2 (clusterfs?). This changes
the semantics of the DELETE_SELF event when hard links are present. You will get
a DELETE_SELF event everytime a hard link is deleted, and the cookie field will
contain the number of links still present. If the cookie is zero, then you will
get a IGNORE event afterwards. But, let me warn anyone who is using DELETE_SELF,
you will only get the DELETE_SELF when the inode goes away, which means if
someone opens the file then unlinks it, the event won't be sent until the person
closes the filedescriptor, and the inode can go away. If you want to be notified
immediately when a file goes away, watch the parent directory of the file.
Index: linux/include/linux/fsnotify.h
===================================================================
--- linux.orig/include/linux/fsnotify.h 2005-08-28 19:41:01.000000000 -0400
+++ linux/include/linux/fsnotify.h 2005-09-20 18:46:15.000000000 -0400
@@ -63,8 +63,9 @@
*/
static inline void fsnotify_inoderemove(struct inode *inode)
{
- inotify_inode_queue_event(inode, IN_DELETE_SELF, 0, NULL);
- inotify_inode_is_dead(inode);
+ inotify_inode_queue_event(inode, IN_DELETE_SELF, inode->i_nlink, NULL);
+ if (inode->i_nlink == 0)
+ inotify_inode_is_dead(inode);
}
/*
--
Configure bugmail: http://bugzilla.ubuntu.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug, or are watching the QA contact.
More information about the kernel-bugs
mailing list