patch update to ~51

David Woodhouse dwmw2 at infradead.org
Mon Jun 6 14:40:38 UTC 2005


On Sat, 2005-06-04 at 15:43 -0500, Timothy R. Chavez wrote:
> Ok, this appears to be working now with my changes.
> 
> I'm going to leave tests going all night and come back tommorrow and
> if all goes well, post a patch.

OK. I assume you're working from audit.55. I'm going to consolidate all
the auditfs patches into one, and add this. Sorry, debugging statements
with side effects aren't wonderfully clever :)

--- linux-2.6.9/kernel/auditfs.c	2005-06-03 18:06:10.000000000 +0100
+++ linux-2.6.9/kernel/auditfs.c	2005-06-06 15:13:22.000000000 +0100
@@ -541,10 +541,13 @@ audit_remove_watch_exit:
 
 struct audit_watch *audit_watch_get(struct audit_watch *watch)
 {
+	int new;
+
 	if (watch) {
-		BUG_ON(!atomic_read(&watch->w_count));
+		new = atomic_inc_return(&watch->w_count);
+		BUG_ON(c == 1);
 		dprintk("Increase count on watch %p to %d\n",
-		       watch, atomic_inc_return(&watch->w_count));
+		       watch, c);
 	}
 
 	return watch;

> 

-- 
dwmw2




More information about the Linux-audit mailing list