Bug 6021 - smbclient du command does not recuse properly
smbclient du command does not recuse properly
Status: RESOLVED FIXED
Product: Samba 3.2
Classification: Unclassified
Component: Client tools
3.2.7
All Linux
: P3 major
: ---
Assigned To: Jeremy Allison
Samba QA Contact
:
: 5785 6023 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2009-01-08 09:58 UTC by Howard Wilkinson
Modified: 2009-01-21 09:01 UTC (History)
2 users (show)

See Also:


Attachments
Patch to client.c against release 3.2.6, use patch -p1 in root samba directory (949 bytes, patch)
2009-01-08 10:00 UTC, Howard Wilkinson
no flags Details
Patch (982 bytes, patch)
2009-01-08 16:04 UTC, Jeremy Allison
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Howard Wilkinson 2009-01-08 09:58:24 UTC
I have been using smbclient under Amanda as a backup solution for some time. It has worked fine until an upgrade somewhere in the 3.2.x series probably 3.2.5 but it could have been earlier.

After some investigation I have found a problem in the client.c code. If do_list_helper is called with a NULL pointer for the mntpoint argument then the search for files always starts with '(null)/' which never matches so no recursion happens.

I have a patch which I will attempt to attach! But it may not be the correct way to fix this problem. Although it works for me.

The problem arises with the following dialog

smbclient //server/data -U backup%password
archive 0
recurse
du

This always report 0 bytes if the root directory only contains other directories.
Comment 1 Howard Wilkinson 2009-01-08 10:00:40 UTC
Created attachment 3863 [details]
Patch to client.c against release 3.2.6, use patch -p1 in root samba directory
Comment 2 Jeremy Allison 2009-01-08 16:04:43 UTC
Created attachment 3864 [details]
Patch

I think this one is the correct patch. I'm going to check this with more recursive tests. Thanks !
Jeremy.
Comment 3 Jeremy Allison 2009-01-12 02:02:36 UTC
*** Bug 6023 has been marked as a duplicate of this bug. ***
Comment 4 Jeremy Allison 2009-01-12 02:03:22 UTC
*** Bug 5785 has been marked as a duplicate of this bug. ***
Comment 5 Karolin Seeger 2009-01-21 09:01:00 UTC
The patch will be included in 3.2.8.
Closing out bug report.
Please re-open if it's still an issue.

Thanks for reporting!