[Ocfs2-commits] mfasheh commits r842 - trunk/src
svn-commits at oss.oracle.com
svn-commits at oss.oracle.com
Mon Apr 5 19:11:44 CDT 2004
Author: mfasheh
Date: 2004-04-05 18:11:42 -0500 (Mon, 05 Apr 2004)
New Revision: 842
Modified:
trunk/src/namei.c
Log:
* Fix a bug where we were passing the wrong inodes to acquire/release
in ocfs_rename. This may have messed up some of our caching in the
past.
Modified: trunk/src/namei.c
===================================================================
--- trunk/src/namei.c 2004-04-02 23:03:12 UTC (rev 841)
+++ trunk/src/namei.c 2004-04-05 23:11:42 UTC (rev 842)
@@ -1067,7 +1067,7 @@
oldfe_flags |= FLAG_FILE_RENAME;
status = ocfs_acquire_lock(osb, oldfe_lockid, OCFS_DLM_EXCLUSIVE_LOCK,
- oldfe_flags, &oldfe_lock, NULL, old_dir);
+ oldfe_flags, &oldfe_lock, NULL, old_inode);
if (status < 0) {
LOG_ERROR_STATUS(status);
goto finally;
@@ -1289,23 +1289,23 @@
}
bail:
- if (new_inode)
- iput(new_inode);
-
if (oldfe_lock) {
ocfs_release_lock(osb, oldfe_lockid,
OCFS_DLM_EXCLUSIVE_LOCK,
- oldfe_flags, oldfe_lock, NULL, old_dir);
+ oldfe_flags, oldfe_lock, NULL, old_inode);
ocfs_put_lockres(oldfe_lock);
}
if (newfe_lock) {
ocfs_release_lock(osb, newfe_lockid,
OCFS_DLM_EXCLUSIVE_LOCK,
- newfe_flags, newfe_lock, NULL, new_dir);
+ newfe_flags, newfe_lock, NULL, new_inode);
ocfs_put_lockres(newfe_lock);
}
+ if (new_inode)
+ iput(new_inode);
+
if (tmpfe)
ocfs_release_file_entry (tmpfe);
if (oldfe_bh) {
More information about the Ocfs2-commits
mailing list