[SCM] Samba Shared Repository - branch master updated
Günther Deschner
gd at samba.org
Mon May 3 06:45:56 MDT 2010
The branch, master has been updated
via fe1617a... s3-lanman: fix api_DosPrintQEnum().
from 84aea47... s3: re-run make samba3-idl.
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit fe1617a818b13b2ff2289e3afd33f2ddcfa76124
Author: Günther Deschner <gd at samba.org>
Date: Mon May 3 13:42:32 2010 +0200
s3-lanman: fix api_DosPrintQEnum().
This was a subtile bug where the OpenPrinter call (called directly via
dispatcher table) was modifiying r->in.printername in a way that all printers on
a server had the printername stripped off the server unc. Once we switch to full
NDR marshalling in inter RAP<->RPC server communication there is no danger
anymore to have these kind of nasty effects.
Guenther
-----------------------------------------------------------------------
Summary of changes:
source3/smbd/lanman.c | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source3/smbd/lanman.c b/source3/smbd/lanman.c
index 954c9c8..ec87dbb 100644
--- a/source3/smbd/lanman.c
+++ b/source3/smbd/lanman.c
@@ -1071,12 +1071,18 @@ static bool api_DosPrintQEnum(connection_struct *conn, uint16 vuid,
uint32_t num_jobs;
struct policy_handle handle;
+ const char *printername;
+
+ printername = talloc_strdup(mem_ctx, printer_info[i].info2.printername);
+ if (printername == NULL) {
+ goto err;
+ }
ZERO_STRUCT(handle);
ZERO_STRUCT(devmode_ctr);
status = rpccli_spoolss_OpenPrinter(cli, mem_ctx,
- printer_info[i].info2.printername,
+ printername,
NULL,
devmode_ctr,
SEC_FLAG_MAXIMUM_ALLOWED,
--
Samba Shared Repository
More information about the samba-cvs
mailing list