[virt-tools-list] [PATCH virt-viewer] Fail if opening the connection fails

Christophe Fergeau cfergeau at redhat.com
Tue Oct 23 08:21:07 UTC 2012


On Mon, Oct 22, 2012 at 08:41:46PM +0200, Guido Günther wrote:
> instead of returning True. Which then fails with the misleading error

Looks good, though I don't fully understand when this function is supposed
to return FALSE (it's returning TRUE if priv->dom is not set for example,
and the default impl also returns TRUE).
ACK

Christophe

> 
> (virt-viewer:18631): Gtk-WARNING **: Attempting to add a widget with type
> VncDisplay to a container of type VirtViewerDisplayVnc, but the widget is
> already inside a container of type VirtViewerDisplayVnc, please use
> gtk_widget_reparent()
> ---
>  src/virt-viewer.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/virt-viewer.c b/src/virt-viewer.c
> index bada5a9..bcab749 100644
> --- a/src/virt-viewer.c
> +++ b/src/virt-viewer.c
> @@ -444,7 +444,7 @@ virt_viewer_open_connection(VirtViewerApp *self G_GNUC_UNUSED, int *fd)
>          DEBUG_LOG("Error %s", err && err->message ? err->message : "Unknown");
>          close(pair[0]);
>          close(pair[1]);
> -        return TRUE;
> +        return FALSE;
>      }
>      close(pair[0]);
>      *fd = pair[1];
> -- 
> 1.7.10.4
> 
> _______________________________________________
> virt-tools-list mailing list
> virt-tools-list at redhat.com
> https://www.redhat.com/mailman/listinfo/virt-tools-list
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/virt-tools-list/attachments/20121023/9787325a/attachment.sig>


More information about the virt-tools-list mailing list