On Wed, 2010-05-12 at 13:32 +0200, Gerd Hoffmann wrote:
> + } else if (strcmp(interface->type, VD_INTERFACE_NET_WIRE) == 0) {
> #ifdef HAVE_SLIRP
> - NetWireInterface * net_wire = (NetWireInterface *)interface;
> - red_printf("VD_INTERFACE_NET_WIRE");
> - if (red_tunnel) {
> - red_printf("net wire already attached");
> - return;
> - }
> - if (interface->major_version != VD_INTERFACE_NET_WIRE_MAJOR ||
> - interface->minor_version < VD_INTERFACE_NET_WIRE_MINOR) {
> - red_printf("unsuported net wire interface");
> - return;
> - }
> - red_tunnel = red_tunnel_attach(core, net_wire);
> + NetWireInterface * net_wire = (NetWireInterface *)interface;
> + red_printf("VD_INTERFACE_NET_WIRE");
> + if (red_tunnel) {
> + red_printf("net wire already attached");
> + return -1;
> + }
> + if (interface->major_version != VD_INTERFACE_NET_WIRE_MAJOR ||
> + interface->minor_version < VD_INTERFACE_NET_WIRE_MINOR) {
> + red_printf("unsuported net wire interface");
> + return -1;
> + }
> + red_tunnel = red_tunnel_attach(core, net_wire);
> #else
> - red_printf("unsupported net wire interface");
> + red_printf("unsupported net wire interface");
> #endif
The switch from not returning anything to returning -1 on failure means
that #else HAVE_SLIRP case need to return -1.
--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Alexander Larsson Red Hat, Inc
[email protected] [email protected]
He's a sword-wielding hunchbacked messiah haunted by memories of 'Nam. She's a
wealthy tempestuous vampire with the power to see death. They fight crime!
_______________________________________________
Spice-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/spice-devel