summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2010-06-16 11:04:34 +0200
committerGünther Deschner <gd@samba.org>2010-06-16 12:15:24 +0200
commit439e7590c920ebdf70e74e15483a3c1e3500331b (patch)
tree66aaa67d294f2e4e1dcd8d55dfaaf118eec4a716
parent1a86532fce51ec2f46b1e8abb1c1838e6793b76b (diff)
downloadsamba-439e7590c920ebdf70e74e15483a3c1e3500331b.tar.gz
samba-439e7590c920ebdf70e74e15483a3c1e3500331b.tar.bz2
samba-439e7590c920ebdf70e74e15483a3c1e3500331b.zip
s3-lanman: Fix return code for "" printqname in api_DosPrintQGetInfo().
Guenther
-rw-r--r--source3/smbd/lanman.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source3/smbd/lanman.c b/source3/smbd/lanman.c
index 8c262628c7..72d488ecab 100644
--- a/source3/smbd/lanman.c
+++ b/source3/smbd/lanman.c
@@ -819,6 +819,11 @@ static bool api_DosPrintQGetInfo(struct smbd_server_connection *sconn,
ZERO_STRUCT(handle);
+ if (QueueName == NULL || (strlen(QueueName) < 1)) {
+ desc.errcode = W_ERROR_V(WERR_INVALID_PARAM);
+ goto out;
+ }
+
status = rpc_connect_spoolss_pipe(conn, &cli);
if (!NT_STATUS_IS_OK(status)) {
DEBUG(0,("api_DosPrintQGetInfo: could not connect to spoolss: %s\n",