]> xenbits.xensource.com Git - libvirt.git/commitdiff
build: silence some clang warnings
authorEric Blake <eblake@redhat.com>
Mon, 14 Feb 2011 23:06:31 +0000 (16:06 -0700)
committerEric Blake <eblake@redhat.com>
Tue, 15 Feb 2011 17:43:40 +0000 (10:43 -0700)
* tools/virsh.c (cmdHelp): Kill dead variables.

tools/virsh.c

index c2d165d34f8268bd41c6bb8c0b41576a9b77fbc8..50d5e33967b8680a1c4ad17eb7064824ad62328d 100644 (file)
@@ -589,8 +589,6 @@ static const vshCmdOptDef opts_help[] = {
 static int
 cmdHelp(vshControl *ctl, const vshCmd *cmd)
  {
-    const vshCmdDef *c;
-    const vshCmdGrp *g;
     const char *name;
 
     name = vshCommandOptString(cmd, "command", NULL);
@@ -615,9 +613,9 @@ cmdHelp(vshControl *ctl, const vshCmd *cmd)
         return TRUE;
     }
 
-    if ((c = vshCmddefSearch(name))) {
+    if (vshCmddefSearch(name)) {
         return vshCmddefHelp(ctl, name);
-    } else if ((g = vshCmdGrpSearch(name))) {
+    } else if (vshCmdGrpSearch(name)) {
         return vshCmdGrpHelp(ctl, name);
     } else {
         vshError(ctl, _("command or command group '%s' doesn't exist"), name);