summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2010-03-01 20:57:52 +0100
committerGünther Deschner <gd@samba.org>2010-03-01 21:15:33 +0100
commitd44dd1005bad8e95ea3c35376488083ebe9261d7 (patch)
tree2b78f6eafcf504d3545a02164265a0be13d23871
parentb797481b8dd99a6e67c69ea5ce4b1c6739c45666 (diff)
downloadsamba-d44dd1005bad8e95ea3c35376488083ebe9261d7.tar.gz
samba-d44dd1005bad8e95ea3c35376488083ebe9261d7.tar.bz2
samba-d44dd1005bad8e95ea3c35376488083ebe9261d7.zip
testprogs: add SetPrinterDataEx test.
Guenther
-rw-r--r--testprogs/win32/spoolss/spoolss.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/testprogs/win32/spoolss/spoolss.c b/testprogs/win32/spoolss/spoolss.c
index 13168f0c12..0ce1603ae8 100644
--- a/testprogs/win32/spoolss/spoolss.c
+++ b/testprogs/win32/spoolss/spoolss.c
@@ -1290,6 +1290,33 @@ static BOOL test_DeletePrinterKey(struct torture_context *tctx,
/****************************************************************************
****************************************************************************/
+static BOOL test_SetPrinterDataEx(struct torture_context *tctx,
+ LPSTR servername,
+ LPSTR keyname,
+ LPSTR valuename,
+ HANDLE handle,
+ DWORD type,
+ LPBYTE buffer,
+ DWORD offered)
+{
+ DWORD err = 0;
+ char tmp[1024];
+
+ torture_comment(tctx, "Testing SetPrinterDataEx(%s - %s)", keyname, valuename);
+
+ err = SetPrinterDataEx(handle, keyname, valuename, type, buffer, offered);
+ if (err) {
+ sprintf(tmp, "SetPrinterDataEx(%s) failed on [%s] (buffer size = %d), error: %s\n",
+ valuename, servername, offered, errstr(err));
+ torture_fail(tctx, tmp);
+ }
+
+ return TRUE;
+}
+
+/****************************************************************************
+****************************************************************************/
+
static BOOL test_PrinterData(struct torture_context *tctx,
LPSTR servername,
HANDLE handle)