summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorJim McDonough <jmcd@samba.org>2003-01-21 14:08:33 +0000
committerJim McDonough <jmcd@samba.org>2003-01-21 14:08:33 +0000
commit85ecf66547e8e86bfd9726d7a08a67cb37672b30 (patch)
treecb947d5adfd740b065a7459ee1981373189261d2 /source3
parent18c2948bc536552ed2949f8fe1d06a72b9cc66dd (diff)
downloadsamba-85ecf66547e8e86bfd9726d7a08a67cb37672b30.tar.gz
samba-85ecf66547e8e86bfd9726d7a08a67cb37672b30.tar.bz2
samba-85ecf66547e8e86bfd9726d7a08a67cb37672b30.zip
Properly display popt errors. Also fix debug to be -d for consistency with other progs.
(This used to be commit c58c84e8066d5d17e1cde99b83d259030f15458b)
Diffstat (limited to 'source3')
-rw-r--r--source3/utils/net.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source3/utils/net.c b/source3/utils/net.c
index 5c1156abf9..33195375f5 100644
--- a/source3/utils/net.c
+++ b/source3/utils/net.c
@@ -536,7 +536,7 @@ static struct functable net_func[] = {
{"force", 'f', POPT_ARG_NONE, &opt_force},
{"timeout", 't', POPT_ARG_INT, &opt_timeout},
{"machine-pass",'P', POPT_ARG_NONE, &opt_machine_pass},
- {"debuglevel", 'D', POPT_ARG_STRING, &debuglevel},
+ {"debuglevel", 'd', POPT_ARG_STRING, &debuglevel},
{ 0, 0, 0, 0}
};
@@ -570,7 +570,8 @@ static struct functable net_func[] = {
}
break;
default:
- d_printf("\nInvalid option %c (%d)\n", (char)opt, opt);
+ d_printf("\nInvalid option %s: %s\n",
+ poptBadOption(pc, 0), poptStrerror(opt));
net_help(argc, argv);
exit(1);
}