summaryrefslogtreecommitdiff
path: root/source3/libsmb/clilist.c
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2008-03-05 19:42:15 +0100
committerJelmer Vernooij <jelmer@samba.org>2008-03-05 19:42:15 +0100
commit63036a6f3380652c0cb54627bdeabcd212fa2f8c (patch)
tree90194f23cb1e6ca483e7773233c326a9b705f85f /source3/libsmb/clilist.c
parentd41d580c600e3228ff8fee5c16c47580f661a240 (diff)
parent932c287a406048759fa1ac4bf86e29d96991ded1 (diff)
downloadsamba-63036a6f3380652c0cb54627bdeabcd212fa2f8c.tar.gz
samba-63036a6f3380652c0cb54627bdeabcd212fa2f8c.tar.bz2
samba-63036a6f3380652c0cb54627bdeabcd212fa2f8c.zip
Merge branch 'v3-2-test' of ssh://git.samba.org/data/git/samba into v3-2-test
(This used to be commit 3482cd9b0e81bbc801f1cec33fca82fc45a3ddef)
Diffstat (limited to 'source3/libsmb/clilist.c')
-rw-r--r--source3/libsmb/clilist.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/source3/libsmb/clilist.c b/source3/libsmb/clilist.c
index e1b16154f2..50918458b0 100644
--- a/source3/libsmb/clilist.c
+++ b/source3/libsmb/clilist.c
@@ -328,7 +328,7 @@ int cli_list_new(struct cli_state *cli,const char *Mask,uint16 attribute,
&rparam, &param_len,
&rdata, &data_len) &&
cli_is_dos_error(cli)) {
- /* we need to work around a Win95 bug - sometimes
+ /* We need to work around a Win95 bug - sometimes
it gives ERRSRV/ERRerror temprarily */
uint8 eclass;
uint32 ecode;
@@ -337,6 +337,20 @@ int cli_list_new(struct cli_state *cli,const char *Mask,uint16 attribute,
SAFE_FREE(rparam);
cli_dos_error(cli, &eclass, &ecode);
+
+ /*
+ * OS/2 might return "no more files",
+ * which just tells us, that searchcount is zero
+ * in this search.
+ * Guenter Kukkukk <linux@kukkukk.com>
+ */
+
+ if (eclass == ERRDOS && ecode == ERRnofiles) {
+ ff_searchcount = 0;
+ cli_reset_error(cli);
+ break;
+ }
+
if (eclass != ERRSRV || ecode != ERRerror)
break;
smb_msleep(100);