]> granicus.if.org Git - pdns/commitdiff
pdnsutil: provide helpful output with command help
authorPieter Lexis <pieter.lexis@powerdns.com>
Mon, 8 Feb 2016 16:06:35 +0000 (17:06 +0100)
committerPieter Lexis <pieter.lexis@powerdns.com>
Mon, 8 Feb 2016 16:06:35 +0000 (17:06 +0100)
Closes #1965

pdns/pdnsutil.cc

index 7a2e25ca79f9e252b54de8f3cdf9b11d3d428845..60ec2acd893483db63f10894ac32db3097dae47e 100644 (file)
@@ -1809,7 +1809,7 @@ try
 
   g_verbose = g_vm.count("verbose");
 
-  if(cmds.empty() || g_vm.count("help")) {
+  if(cmds.empty() || g_vm.count("help") || cmds[0] == "help") {
     cerr<<"Usage: \npdnsutil [options] <command> [params ..]\n"<<endl;
     cerr<<"Commands:"<<endl;
     cerr<<"activate-tsig-key ZONE NAME {master|slave}"<<endl;