const NetdevTapOptions *tap;
int fd, vnet_hdr = 0, i = 0, queues;
/* for the no-fd, no-helper case */
- const char *script;
- const char *downscript;
Error *err = NULL;
const char *vhostfdname;
char ifname[128];
tap = &netdev->u.tap;
queues = tap->has_queues ? tap->queues : 1;
vhostfdname = tap->vhostfd;
- script = tap->script;
- downscript = tap->downscript;
/* QEMU hubs do not support multiqueue tap, in this case peer is set.
* For -netdev, peer is always NULL. */
}
net_init_tap_one(tap, peer, "tap", name, NULL,
- script, downscript,
+ NULL, NULL,
vhostfdname, vnet_hdr, fd, &err);
if (err) {
error_propagate(errp, err);
}
net_init_tap_one(tap, peer, "tap", name, ifname,
- script, downscript,
+ NULL, NULL,
tap->vhostfds ? vhost_fds[i] : NULL,
vnet_hdr, fd, &err);
if (err) {
}
net_init_tap_one(tap, peer, "bridge", name, ifname,
- script, downscript, vhostfdname,
+ NULL, NULL, vhostfdname,
vnet_hdr, fd, &err);
if (err) {
error_propagate(errp, err);
return -1;
}
} else {
+ const char *script = tap->script;
+ const char *downscript = tap->downscript;
g_autofree char *default_script = NULL;
g_autofree char *default_downscript = NULL;
if (tap->vhostfds) {