From: John W. Linville Date: Tue, 10 Feb 2009 18:53:01 +0000 (-0500) Subject: airo: correct improper initialization of local variable X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=bc8263f1d86946ffe97eb249fc1d6660da1e1055;p=openwrt%2Fstaging%2Fblogic.git airo: correct improper initialization of local variable Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/airo.c b/drivers/net/wireless/airo.c index c44f38895fbe..a3e324e0ca83 100644 --- a/drivers/net/wireless/airo.c +++ b/drivers/net/wireless/airo.c @@ -4727,7 +4727,7 @@ static int proc_stats_rid_open( struct inode *inode, StatsRid stats; int i, j; __le32 *vals = stats.vals; - int len = le16_to_cpu(stats.len); + int len; if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) return -ENOMEM; @@ -4738,6 +4738,7 @@ static int proc_stats_rid_open( struct inode *inode, } readStatsRid(apriv, &stats, rid, 1); + len = le16_to_cpu(stats.len); j = 0; for(i=0; statsLabels[i]!=(char *)-1 && i*4