smbclient, find, and NetBSD (fwd)

Gerald Carter gcarter at valinux.com
Thu Apr 5 13:35:58 GMT 2001


This has come up before.  Anyone want to comment (other than an OS
specific #ifdef)?





Cheers, jerry

---------- Forwarded message ----------
Date: Thu, 5 Apr 2001 09:26:18 -0400 (EDT)
From: Claude Marinier <claude.marinier at dreo.dnd.ca>
To: samba at lists.samba.org
Subject: smbclient, find, and NetBSD

Dear developers,

I often use smbclient from NetBSD 1.5 (i386) to an NT4.6a box. When I
leave recursion off and do an 'mput', the find fails because NetBSD's find
does not have the '-maxdepth' option.

The problem is in samba/source/client/client.c at line 1168. Here is the
code that causes the problem with a temporary fix.

> 		if (recurse)
> 			slprintf(cmd,sizeof(pstring)-1,
> 				"find . -name \"%s\" -print > %s",p,tmpname);
> 		else
> 			slprintf(cmd,sizeof(pstring)-1,
> 				"ls -1 %s > %s",p,tmpname);
> //			slprintf(cmd,sizeof(pstring)-1,
> //				"find . -maxdepth 1 -name \"%s\" -print > %s",p,tmpname);

Please suggest a better fix and add it to your list of things to do. I do
not know how autoconf could deal with this.

By the way, thank you for great software.

Thanks.

-- 
Claude Marinier, Information Technology Group    claude.marinier at dreo.dnd.ca
Defence Research Establishment Ottawa (DREO)    (613) 998-4901  FAX 998-2675
3701 Carling Avenue, Ottawa, Ontario  K1A 0Z4         http://www.dreo.dnd.ca



-- 
To unsubscribe from this list go to the following URL and read the
instructions:  http://lists.samba.org/mailman/listinfo/samba





More information about the samba-technical mailing list