9
0
Fork 0

Fix bug in 405 ethernet driver; allocated data not cleared!

This commit is contained in:
stroese 2004-07-02 14:36:35 +00:00
parent 78953f2f93
commit 18f71f27ae
1 changed files with 2 additions and 0 deletions

View File

@ -944,6 +944,7 @@ int ppc_4xx_eth_initialize (bd_t * bis)
"Cannot allocate eth_device %d\n", eth_num);
return (-1);
}
memset(dev, 0, sizeof(*dev));
/* Allocate our private use data */
hw = (EMAC_405_HW_PST) malloc (sizeof (*hw));
if (hw == NULL) {
@ -953,6 +954,7 @@ int ppc_4xx_eth_initialize (bd_t * bis)
free (dev);
return (-1);
}
memset(hw, 0, sizeof(*hw));
switch (eth_num) {
case 0: