1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-24 21:34:56 +03:00

Fix for bug 222 from Marcin Owsiany.

Don't get stuck in an infinite loop listing directories recursively
if the server returns an empty directory name.  This can happen with
incorrect i18n configuration on a Samba server.
This commit is contained in:
Tim Potter 0001-01-01 00:00:00 +00:00
parent 3498624d94
commit f93a2831f1

View File

@ -481,6 +481,11 @@ static void do_list_helper(file_info *f, const char *mask, void *state)
pstring mask2;
char *p;
if (!f->name[0]) {
d_printf("Empty dir name returned. Possible server misconfiguration.\n");
return;
}
pstrcpy(mask2, mask);
p = strrchr_m(mask2,'\\');
if (!p) return;