projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e3a5cd9
)
[TG3]: Fix a memory leak.
author
Adrian Bunk
<bunk@stusta.de>
Thu, 6 Apr 2006 05:21:04 +0000
(22:21 -0700)
committer
David S. Miller
<davem@sunset.davemloft.net>
Mon, 10 Apr 2006 05:25:27 +0000
(22:25 -0700)
This patch fixes a memory leak (buf wasn't freed) spotted by the
Coverity checker.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/tg3.c
patch
|
blob
|
history
diff --git
a/drivers/net/tg3.c
b/drivers/net/tg3.c
index 0b5358072172a9f0c95d008ea21447aa59ca0595..d6047bd6805d44b62a9a7f6d2e676776ca6575df 100644
(file)
--- a/
drivers/net/tg3.c
+++ b/
drivers/net/tg3.c
@@
-8034,9
+8034,13
@@
static int tg3_test_nvram(struct tg3 *tp)
for (i = 0; i < size; i++)
csum8 += buf8[i];
- if (csum8 == 0)
- return 0;
- return -EIO;
+ if (csum8 == 0) {
+ err = 0;
+ goto out;
+ }
+
+ err = -EIO;
+ goto out;
}
/* Bootstrap checksum at offset 0x10 */