From: Julia Lawall Date: Sun, 5 Sep 2010 19:00:26 +0000 (+0200) Subject: drivers/net/wireless/iwlwifi/iwl-agn.c: Fix return value from an unsigned function X-Git-Tag: v2.6.37-rc1~147^2~373^2^2~125 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=950094cb06f3cfd75338d8c197d1d3924724b1a8;p=pandora-kernel.git drivers/net/wireless/iwlwifi/iwl-agn.c: Fix return value from an unsigned function The function has an unsigned return type, but returns a negative constant to indicate an error condition. Another error condition in the same function is indicated by returning 0, and indeed the only call to the function checks for 0 to detect errors, so the return of a negative value it converted to a return of 0. A sematic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // @exists@ identifier f; constant C; @@ unsigned f(...) { <+... * return -C; ...+> } // Signed-off-by: Julia Lawall Signed-off-by: John W. Linville --- Reading git-diff-tree failed