Re: Limit module accept negation?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Samuel Jean wrote:
The patch below is against ipt_limit.c from 2.6.10. It's *untested* but reflects what I told you. It's just an exemple of how you can make
this module behaving the other way arround.



Doh! crapy patch. Attached good one. I hope.
--- ipt_limit.c.orig	2005-01-13 20:13:19.000000000 -0500
+++ ipt_limit.c	2005-01-13 20:14:10.000000000 -0500
@@ -82,11 +82,11 @@
 		/* We're not limited. */
 		r->credit -= r->cost;
 		spin_unlock_bh(&limit_lock);
-		return 1;
+		return 0;
 	}
 
        	spin_unlock_bh(&limit_lock);
-	return 0;
+	return 1;
 }
 
 /* Precision saver. */

[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux