PATCH Re: warnings: msdfs/msdfs.c smbd/quotas.c
Michael Gerdts
Michael.Gerdts at usa.alcatel.com
Fri Jun 29 14:37:18 GMT 2001
The attached patch takes care of the first two warnings. It is not
entirely clear why there are some references in msdfs.c to
conn->vfs_ops.lstat() and other references to lstat() [this patch changes
these to sys_lstat()]. Was this something that was missed during a global
search and replace, and all occurrences should really be the same?
Mike
On Wed, Jun 27, 2001 at 08:11:35AM -0400, Michael Gerdts wrote:
> On SPARC Solaris 8, compiling from CVS gives the following warnings:
>
> I suspect that the first two may be due to a missing
>
> #define _FILE_OFFSET_BITS 64
>
> That seems to make a difference in <sys/stat.h> causing lstat to become
> lstat64.
>
> msdfs/msdfs.c:256: warning: passing arg 2 of `lstat' from incompatible pointer type
> msdfs/msdfs.c:711: warning: passing arg 2 of `lstat' from incompatible pointer type
>
> Not sure about these
>
> smbd/quotas.c:270: warning: static declaration for `xdr_getquota_args' follows non-static
> smbd/quotas.c:279: warning: static declaration for `xdr_getquota_rslt' follows non-static
>
> Mike
>
-------------- next part --------------
Index: msdfs/msdfs.c
===================================================================
RCS file: /cvsroot/samba/source/msdfs/msdfs.c,v
retrieving revision 1.10.4.3
diff -c -r1.10.4.3 msdfs.c
*** msdfs/msdfs.c 8 Apr 2001 20:22:52 -0000 1.10.4.3
--- msdfs/msdfs.c 29 Jun 2001 14:26:38 -0000
***************
*** 253,259 ****
DEBUG(5,("get_referred_path: lstat target: %s\n", path));
! if(lstat(dos_to_unix(path, False),&st) != 0)
{
DEBUG(5,("get_referred_path: %s does not exist.\n",path));
return False;
--- 253,259 ----
DEBUG(5,("get_referred_path: lstat target: %s\n", path));
! if(sys_lstat(dos_to_unix(path, False),&st) != 0)
{
DEBUG(5,("get_referred_path: %s does not exist.\n",path));
return False;
***************
*** 708,714 ****
pstrcat(pathreal, "/");
pstrcat(pathreal, dname);
! if(lstat(pathreal,&st) != 0)
{
DEBUG(4,("lstat error for %s: %s\n",pathreal, strerror(errno)));
continue;
--- 708,714 ----
pstrcat(pathreal, "/");
pstrcat(pathreal, dname);
! if(sys_lstat(pathreal,&st) != 0)
{
DEBUG(4,("lstat error for %s: %s\n",pathreal, strerror(errno)));
continue;
More information about the samba-technical
mailing list