[Ocfs2-commits] mfasheh commits r818 - trunk/src

svn-commits at oss.oracle.com svn-commits at oss.oracle.com
Mon Mar 29 16:46:44 CST 2004


Author: mfasheh
Date: 2004-03-29 16:46:42 -0600 (Mon, 29 Mar 2004)
New Revision: 818

Modified:
   trunk/src/namei.c
Log:
* handle error conditions in mknod more gracefully -- we were leaving
  stuff in a deadlocked state before!



Modified: trunk/src/namei.c
===================================================================
--- trunk/src/namei.c	2004-03-29 22:45:03 UTC (rev 817)
+++ trunk/src/namei.c	2004-03-29 22:46:42 UTC (rev 818)
@@ -226,7 +226,6 @@
 	if (status < 0) {
 		if (status != -EINTR)
 			LOG_ERROR_STATUS (status);
-		ocfs_abort_trans(handle);
 		goto leave;
 	}
 
@@ -241,7 +240,6 @@
 	if (status < 0) {
 		if (status != -EINTR)
 			LOG_ERROR_STATUS(status);
-		ocfs_abort_trans(handle);
 		goto leave;
 	}
 
@@ -313,6 +311,9 @@
 
 	status = 0;
 leave:
+	if ((status < 0) && handle)
+		ocfs_abort_trans(handle);
+
 	if (status == -ENOSPC)
 		LOG_TRACE_STR ("Disk is full");
 	else if (status < 0 && status != -EINTR)



More information about the Ocfs2-commits mailing list