summaryrefslogtreecommitdiff
path: root/source3/utils
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2000-04-30 12:34:26 +0000
committerAndrew Tridgell <tridge@samba.org>2000-04-30 12:34:26 +0000
commit23c0cb01ca5b8bafb3ed9f31c3aa672957c2af86 (patch)
tree5961c3f7790a4e46a05d33f75d377f0324edbfa3 /source3/utils
parentaa6040c7ce96ea974967b4e9ec7d13778d3a43a5 (diff)
downloadsamba-23c0cb01ca5b8bafb3ed9f31c3aa672957c2af86.tar.gz
samba-23c0cb01ca5b8bafb3ed9f31c3aa672957c2af86.tar.bz2
samba-23c0cb01ca5b8bafb3ed9f31c3aa672957c2af86.zip
added cli_list_old() to allow for old style directory listing from
masktest (This used to be commit 8a5c8cfa0ede1d119bf9013e321a497beefd4dda)
Diffstat (limited to 'source3/utils')
-rw-r--r--source3/utils/masktest.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/source3/utils/masktest.c b/source3/utils/masktest.c
index 137866b41c..45c113f112 100644
--- a/source3/utils/masktest.c
+++ b/source3/utils/masktest.c
@@ -30,7 +30,7 @@ static fstring workgroup;
static int got_pass;
static BOOL showall = False;
-
+static BOOL old_list = False;
static char *maskchars = "<>\"?*abc.";
static char *filechars = "abcdefghijklm.";
@@ -190,7 +190,11 @@ static void testpair(struct cli_state *cli, char *mask, char *file)
resultp = res1;
fstrcpy(short_name, "");
finfo = NULL;
- cli_list(cli, mask, aHIDDEN | aDIR, listfn);
+ if (old_list) {
+ cli_list_old(cli, mask, aHIDDEN | aDIR, listfn);
+ } else {
+ cli_list(cli, mask, aHIDDEN | aDIR, listfn);
+ }
if (finfo) {
fstrcpy(short_name, finfo->short_name);
strlower(short_name);
@@ -310,8 +314,8 @@ static void usage(void)
setup_logging(argv[0],True);
- argc -= 2;
- argv += 2;
+ argc -= 1;
+ argv += 1;
TimeInit();
charset_initialise();
@@ -325,7 +329,7 @@ static void usage(void)
seed = time(NULL);
- while ((opt = getopt(argc, argv, "U:s:hm:f:a")) != EOF) {
+ while ((opt = getopt(argc, argv, "U:s:hm:f:ao")) != EOF) {
switch (opt) {
case 'U':
pstrcpy(username,optarg);
@@ -351,6 +355,9 @@ static void usage(void)
case 'a':
showall = 1;
break;
+ case 'o':
+ old_list = True;
+ break;
default:
printf("Unknown option %c (%d)\n", (char)opt, opt);
exit(1);