BUGFIX for ./smbd/close.c that makes magic script work

Emrich Michael (QI/LBS3-RT) * Michael.Emrich at de.bosch.com
Fri Jan 28 15:49:06 GMT 2000



> Hello,
> 
> here are some little bugfixes that makes "magic script" run with Solaris
> 2.7 and maybe other Unix-Systems ...
> 
> The execl() "in ./lib/smbrun.c" searchs not in the "./" path so if you
> define "magic script = magiscript.sh" it does not work.
> 
> A workaround is this in ./smbd/close.c function "static void
> check_magic()"
> Instead of: 
> 	pstrcat(fname,fsp->fsp_name);
> put this in:
> 	pstrcpy(fname,"./"); pstrcat(fname,fsp->fsp_name);
> 
> O.k. this is a quick an dirty solution but it works. A better way would it
> be if it is possible to specify a relativ path in 
> "magic script -Parameter" because users often do not have a write
> permission to the root of the share. 
> Maybe an idea for next version of samba, please let me know what you think
> about that?
>  
> It ist no workaround to put "magic script = ./magiscript.sh in smb.conf" !
> 
> 3. Further more there are a syntax error if in smbrun.c  / smbrun() if
> "HAVE_EXECL" is not defined
> 
> 
> 
> 
> Greetings
> 
> Michael Emrich
> Robert Bosch GmbH ; QI/LBS3-Rt; Postfach 1342; 72703 Reutlingen
> Tel: (07121)/35-4018; Fax: (07121)/35-374018; Internet:
> Michael.Emrich at de.bosch.com
> 


More information about the samba-technical mailing list