patch-2.1.90 linux/fs/hfs/dir.c

Next file: linux/fs/hfs/dir_cap.c
Previous file: linux/fs/hfs/catalog.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.89/linux/fs/hfs/dir.c linux/fs/hfs/dir.c
@@ -95,7 +95,7 @@
 }
 
 /*
- * update_dirs_plus()
+ * update_dirs_minus()
  *
  * Update the fields 'i_size', 'i_nlink', 'i_ctime', 'i_mtime' and
  * 'i_version' of the inodes associated with a directory that has
@@ -138,10 +138,9 @@
 
 	for (i = 0; i < 4; ++i) {
 		if ((de = entry->sys_entry[i]) && (dentry != de)) {
-		    entry->sys_entry[i] = NULL;
-		    dget(de);
-		    d_delete(de);
-		    dput(de);
+		      dget(de);
+		      d_delete(de);
+		      dput(de);
 		}
 	}
 }
@@ -198,7 +197,7 @@
 		        error = -EIO;
    		} else {
 		  if (HFS_I(dir)->d_drop_op)
-		    HFS_I(dir)->d_drop_op(HFS_I(dir)->file_type, dentry);
+		    HFS_I(dir)->d_drop_op(dentry, HFS_I(dir)->file_type);
 		  d_instantiate(dentry, inode);
 		}
 	}
@@ -285,7 +284,7 @@
 	struct hfs_cat_key key;
 	int error;
 
-	if (build_key(&key, dir, dentry->d_name.name, 
+	if (build_key(&key, dir, dentry->d_name.name,
 		      dentry->d_name.len)) {
 		error = -EPERM;
 	} else if (!(victim = hfs_cat_get(entry->mdb, &key))) {
@@ -386,15 +385,15 @@
 		} else {
 		  /* no existing inodes. just drop negative dentries */
 		  if (HFS_I(new_dir)->d_drop_op) 
-		    HFS_I(new_dir)->d_drop_op(HFS_I(new_dir)->file_type,
-						   new_dentry);
+		    HFS_I(new_dir)->d_drop_op(new_dentry, 
+					      HFS_I(new_dir)->file_type);
 		  update_dirs_plus(new_parent, is_dir);
 		}
 
 		/* update dcache */
 		d_move(old_dentry, new_dentry);
 	}
-	 
+
 	hfs_cat_put(victim);	/* Note that hfs_cat_put(NULL) is safe. */
 	return error;
 }

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov