[PATCH] s3-printing: fix move_driver_to_download_area() error paths
ddiss at suse.de
Mon Feb 28 10:29:06 MST 2011
On Fri, 25 Feb 2011 16:48:35 -0800
Jeremy Allison <jra at samba.org> wrote:
> Doesn't pass "make test" in master - can you fix that
> please ?
Sloppiness on my part, I did not have /usr/share/cups populated on my
build system so missed this failure. Thanks to asn for pointing me in
the right direction.
samba3.posix_s3.rpc.spoolss.driver fails with the xattr_tdb vfs module
loaded as a part of make test. The (now checked) create_directory() call
in move_driver_to_download_area() fails, uncovering another bug in the
printer driver upload code path.
move_driver_to_download_area() creates a new conn_struct for
manipulating files in [print$]. The VFS layer is plumbed through with
the call to create_conn_struct(), however SMB_VFS_CONNECT() is never
called. Many vfs modules expect state stored at connect time with
SMB_VFS_HANDLE_SET_DATA() to be available on any IO operation and fail
if this is not the case.
A possible fix is to call SMB_VFS_CONNECT() following
create_conn_struct() in move_driver_to_download_area(), but along with
the force_user/group changes move_driver_to_download_area() is looking
more and more like make_connection_snum().
I'll add this info to bug 7921.
More information about the samba-technical