]> Git Repo - qemu.git/commitdiff
vnc: Drop superfluous conditionals around g_strdup()
authorMarkus Armbruster <[email protected]>
Fri, 6 Jun 2014 16:47:44 +0000 (18:47 +0200)
committerGerd Hoffmann <[email protected]>
Thu, 19 Jun 2014 10:48:07 +0000 (12:48 +0200)
Signed-off-by: Markus Armbruster <[email protected]>
Signed-off-by: Gerd Hoffmann <[email protected]>
ui/vnc.c

index d771a2cd4f6021ebd4e3769ea8080fe920015ed8..6c9d4f34923a59d8d33d14475fa882efa9f6c0ce 100644 (file)
--- a/ui/vnc.c
+++ b/ui/vnc.c
@@ -3009,10 +3009,7 @@ int vnc_display_password(DisplayState *ds, const char *password)
     }
 
     g_free(vs->password);
-    vs->password = NULL;
-    if (password) {
-        vs->password = g_strdup(password);
-    }
+    vs->password = g_strdup(password);
 
     return 0;
 }
This page took 0.030456 seconds and 4 git commands to generate.