[virt-tools-list] Small dead code removal
Richard W.M. Jones
rjones at redhat.com
Wed Aug 3 10:21:09 UTC 2011
On Wed, Aug 03, 2011 at 09:19:47AM +0200, Pavel Raiskup wrote:
> Hi, I would like to propose small patch removing unreachable
> condition in virt-viewer code.
>
> Pavel
> >From 7ad1aa36f9acf61a9b19dbac9b7892a146037df6 Mon Sep 17 00:00:00 2001
> From: Pavel Raiskup <praiskup at redhat.com>
> Date: Tue, 2 Aug 2011 14:42:48 +0200
> Subject: [PATCH] unreachable condition removed
>
> ---
> src/virt-viewer-auth.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/src/virt-viewer-auth.c b/src/virt-viewer-auth.c
> index 3d63dcd..811051f 100644
> --- a/src/virt-viewer-auth.c
> +++ b/src/virt-viewer-auth.c
> @@ -63,7 +63,7 @@ virt_viewer_auth_collect_credentials(const char *type,
> message = g_strdup_printf("Authentication is required for the %s connection to:\n\n"
> "<b>%s</b>\n\n",
> type,
> - address ? address : "[unknown]");
> + address);
> } else {
> message = g_strdup_printf("Authentication is required for the %s connection:\n",
> type);
"address" is always non-NULL here because the enclosing condition (not
shown above) is "if (address) { ..."
ACK.
Rich.
--
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming blog: http://rwmj.wordpress.com
Fedora now supports 80 OCaml packages (the OPEN alternative to F#)
http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora
More information about the virt-tools-list
mailing list