aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/dummy.c
diff options
context:
space:
mode:
authorNicolas Dichtel <nicolas.dichtel@6wind.com>2006-07-21 18:09:07 -0400
committerDavid S. Miller <davem@davemloft.net>2006-07-21 18:09:07 -0400
commit9ed36279f68c990d65cd3d64f27d81313474a118 (patch)
treed79111b110792eee5462a845e2655b09c4da156e /drivers/net/dummy.c
parent4a9c74e5830444c1c3235848e06402c1d2ece1ea (diff)
[DUMMY]: Avoid an oops when dummy_init_one() failed
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dummy.c')
-rw-r--r--drivers/net/dummy.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/dummy.c b/drivers/net/dummy.c
index 36d511729f71..2146cf74425e 100644
--- a/drivers/net/dummy.c
+++ b/drivers/net/dummy.c
@@ -132,6 +132,7 @@ static int __init dummy_init_module(void)
132 for (i = 0; i < numdummies && !err; i++) 132 for (i = 0; i < numdummies && !err; i++)
133 err = dummy_init_one(i); 133 err = dummy_init_one(i);
134 if (err) { 134 if (err) {
135 i--;
135 while (--i >= 0) 136 while (--i >= 0)
136 dummy_free_one(i); 137 dummy_free_one(i);
137 } 138 }