patch-2.4.0-test11 linux/fs/dnotify.c

Next file: linux/fs/dquot.c
Previous file: linux/fs/devpts/inode.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.0-test10/linux/fs/dnotify.c linux/fs/dnotify.c
@@ -103,14 +103,14 @@
 	write_lock(&dn_lock);
 	prev = &inode->i_dnotify;
 	while ((dn = *prev) != NULL) {
-		if ((dn->dn_mask & event) == 0) {
-			prev = &dn->dn_next;
-			continue;
-		}
 		if (dn->dn_magic != DNOTIFY_MAGIC) {
 		        printk(KERN_ERR "__inode_dir_notify: bad magic "
 				"number in dnotify_struct!\n");
-		        return;
+		        goto out;
+		}
+		if ((dn->dn_mask & event) == 0) {
+			prev = &dn->dn_next;
+			continue;
 		}
 		fown = &dn->dn_filp->f_owner;
 		if (fown->pid)
@@ -125,6 +125,7 @@
 	}
 	if (changed)
 		redo_inode_mask(inode);
+out:
 	write_unlock(&dn_lock);
 }
 

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)