2007-11-09 08:33:46

by Frank Lichtenheld

[permalink] [raw]
Subject: [PATCH][B43]: silence a bogus gcc warning

inititalise ret to 0 to avoid the following bogus warning:
CC [M] drivers/net/wireless/b43/debugfs.o
drivers/net/wireless/b43/debugfs.c: In function =E2=80=98b43_debugfs_re=
ad=E2=80=99:
drivers/net/wireless/b43/debugfs.c:355: warning: =E2=80=98ret=E2=80=99 =
may be used uninitialized in this function

Signed-off-by: Frank Lichtenheld <[email protected]>
---
drivers/net/wireless/b43/debugfs.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/b43/debugfs.c b/drivers/net/wireless/=
b43/debugfs.c
index 734e70e..d8ac058 100644
--- a/drivers/net/wireless/b43/debugfs.c
+++ b/drivers/net/wireless/b43/debugfs.c
@@ -352,7 +352,7 @@ static ssize_t b43_debugfs_read(struct file *file, =
char __user *userbuf,
struct b43_wldev *dev;
struct b43_debugfs_fops *dfops;
struct b43_dfs_file *dfile;
- ssize_t ret;
+ ssize_t ret =3D 0;
char *buf;
const size_t bufsize =3D 1024 * 128;
const size_t buforder =3D get_order(bufsize);
--=20
1.5.3.4