aboutsummaryrefslogtreecommitdiffstats
path: root/hw/sun4m.c
diff options
context:
space:
mode:
authorblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2008-11-29 16:42:40 +0000
committerblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2008-11-29 16:42:40 +0000
commitce802585a9c18d93fc01fed320a3e066f52ef879 (patch)
tree21f12f619e8bb84d6c28c0905675a54d41cbcbf2 /hw/sun4m.c
parent6c173b3c09548fd5cd82de08646dfe939ec9416e (diff)
Don't rely on the fact that MAX_FD is 2 (Herve Poussineau)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5810 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'hw/sun4m.c')
-rw-r--r--hw/sun4m.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/sun4m.c b/hw/sun4m.c
index 4069cd3c4..2035b6c92 100644
--- a/hw/sun4m.c
+++ b/hw/sun4m.c
@@ -1589,7 +1589,7 @@ static void sun4c_hw_init(const struct sun4c_hwdef *hwdef, ram_addr_t RAM_size,
if (hwdef->fd_base != (target_phys_addr_t)-1) {
/* there is zero or one floppy drive */
- fd[1] = fd[0] = NULL;
+ memset(fd, 0, sizeof(fd));
drive_index = drive_get_index(IF_FLOPPY, 0, 0);
if (drive_index != -1)
fd[0] = drives_table[drive_index].bdrv;