summaryrefslogtreecommitdiff
path: root/vl.c
diff options
context:
space:
mode:
authorbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2004-04-04 09:37:47 +0000
committerbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2004-04-04 09:37:47 +0000
commit0f2f1121569d37b3b332032a9604219b644c9e30 (patch)
tree54f4156cce0795ec689d859df8ceb1ffb8e2ba9a /vl.c
parent4721c4575004f9436e3c167f4daa66e2a2d6a3ff (diff)
downloadqemu-0f2f1121569d37b3b332032a9604219b644c9e30.tar.gz
qemu-0f2f1121569d37b3b332032a9604219b644c9e30.tar.bz2
qemu-0f2f1121569d37b3b332032a9604219b644c9e30.zip
tun-fd fix
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@700 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'vl.c')
-rw-r--r--vl.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/vl.c b/vl.c
index cefe0e9ab4..72238efcdb 100644
--- a/vl.c
+++ b/vl.c
@@ -1728,6 +1728,9 @@ int main(int argc, char **argv)
macaddr[4] = 0x34;
macaddr[5] = 0x56;
+ for(i = 0; i < MAX_NICS; i++)
+ nd_table[i].fd = -1;
+
for(;;) {
c = getopt_long_only(argc, argv, "hm:d:n:sp:L:", long_options, &long_index);
if (c == -1)
@@ -1934,7 +1937,6 @@ int main(int argc, char **argv)
/* init host network redirectors */
for(i = 0; i < MAX_NICS; i++) {
NetDriverState *nd = &nd_table[i];
- nd->fd = -1;
/* init virtual mac address */
nd->macaddr[0] = macaddr[0];
nd->macaddr[1] = macaddr[1];