diff mbox

airo: Fix integer overflow warning

Message ID 200911252255.11570.mb@bu3sch.de (mailing list archive)
State Not Applicable, archived
Headers show

Commit Message

Michael Buesch Nov. 25, 2009, 9:55 p.m. UTC
None
diff mbox

Patch

Index: wireless-testing/drivers/net/wireless/airo.c
===================================================================
--- wireless-testing.orig/drivers/net/wireless/airo.c	2009-11-01 13:58:47.000000000 +0100
+++ wireless-testing/drivers/net/wireless/airo.c	2009-11-25 22:49:18.000000000 +0100
@@ -4806,7 +4806,7 @@  static int airo_config_commit(struct net
 
 static inline int sniffing_mode(struct airo_info *ai)
 {
-	return le16_to_cpu(ai->config.rmode & RXMODE_MASK) >=
+	return (le16_to_cpu(ai->config.rmode) & le16_to_cpu(RXMODE_MASK)) >=
 		le16_to_cpu(RXMODE_RFMON);
 }