PERFORCE change 71652 for review

Robert Watson rwatson at FreeBSD.org
Wed Feb 23 11:46:31 GMT 2005


http://perforce.freebsd.org/chv.cgi?CH=71652

Change 71652 by rwatson at rwatson_paprika on 2005/02/23 11:46:19

	When replacing an existing mac_bsdextended rule, perform the
	replacement under the mac_bsdextended_mtx mutex so as not to race
	with other code using the rule pointer or rule.

Affected files ...

.. //depot/projects/trustedbsd/mac/sys/security/mac_bsdextended/mac_bsdextended.c#81 edit

Differences ...

==== //depot/projects/trustedbsd/mac/sys/security/mac_bsdextended/mac_bsdextended.c#81 (text+ko) ====

@@ -186,10 +186,10 @@
 				rule_slots = index + 1;
 			rule_count++;
 		} else {
+			/* printf("replacement\n"); */
+			*rules[index] = temprule;
 			mtx_unlock(&mac_bsdextended_mtx);
 			FREE(ruleptr, M_MACBSDEXTENDED);
-			/* printf("replacement\n"); */
-			*rules[index] = temprule;
 		}
 		mtx_unlock(&mac_bsdextended_mtx);
 		return (0);
To Unsubscribe: send mail to majordomo at trustedbsd.org
with "unsubscribe trustedbsd-cvs" in the body of the message



More information about the trustedbsd-cvs mailing list