summaryrefslogtreecommitdiff
path: root/source4/setup
diff options
context:
space:
mode:
authorRafal Szczesniak <mimir@samba.org>2005-08-22 14:32:58 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:34:20 -0500
commit55e746ad560d4406821bc2d721cbb929b79a7a0a (patch)
treed9baa6d6d7651e3f95313699510335c714a2e681 /source4/setup
parent5bd6a114711c0033403a656b42574380a6ebcd3d (diff)
downloadsamba-55e746ad560d4406821bc2d721cbb929b79a7a0a.tar.gz
samba-55e746ad560d4406821bc2d721cbb929b79a7a0a.tar.bz2
samba-55e746ad560d4406821bc2d721cbb929b79a7a0a.zip
r9477: Convert popt options to an ejs object. Doesn't seem to break anything
except of popt help (-h) option (unexpected ?). rafal (This used to be commit 1990793b23d6198a85ce1bdf6ad43e12015db203)
Diffstat (limited to 'source4/setup')
-rwxr-xr-xsource4/setup/newuser6
-rwxr-xr-xsource4/setup/provision8
2 files changed, 7 insertions, 7 deletions
diff --git a/source4/setup/newuser b/source4/setup/newuser
index f5015611b9..cf2c7b8382 100755
--- a/source4/setup/newuser
+++ b/source4/setup/newuser
@@ -6,8 +6,7 @@ exec smbscript "$0" ${1+"$@"}
Released under the GNU GPL v2 or later
*/
-options = new Object();
-ok = GetOptions(ARGV, options,
+options = GetOptions(ARGV,
"POPT_AUTOHELP",
"POPT_COMMON_SAMBA",
"POPT_COMMON_VERSION",
@@ -15,7 +14,8 @@ ok = GetOptions(ARGV, options,
'unixname=s',
'password=s',
'quiet');
-if (ok == false) {
+
+if (options == undefined) {
println("Failed to parse options: " + options.ERROR);
return -1;
}
diff --git a/source4/setup/provision b/source4/setup/provision
index a9bbfa6a26..35c9d64f80 100755
--- a/source4/setup/provision
+++ b/source4/setup/provision
@@ -6,8 +6,7 @@ exec smbscript "$0" ${1+"$@"}
Released under the GNU GPL v2 or later
*/
-options = new Object();
-ok = GetOptions(ARGV, options,
+options = GetOptions(ARGV,
"POPT_AUTOHELP",
"POPT_COMMON_SAMBA",
"POPT_COMMON_VERSION",
@@ -29,8 +28,9 @@ ok = GetOptions(ARGV, options,
'users=s',
'quiet',
'blank');
-if (ok == false) {
- println("Failed to parse options: " + options.ERROR);
+
+if (options == undefined) {
+ println("Failed to parse options: ", options.ERROR);
return -1;
}