[SCM] Samba Shared Repository - branch master updated - release-4-0-0alpha6-494-gafa960c

Günther Deschner gd at samba.org
Thu Feb 5 15:06:10 GMT 2009


The branch, master has been updated
       via  afa960cbbcd609123d710c301e7a9a070c1fed70 (commit)
       via  c9e64100d445b7c8c447629c0535722a8e59d1f9 (commit)
       via  b03913cbc684d3bd5e39701e103da875330f3f32 (commit)
       via  60fc7dadd6b9af645d5e1a8fba2f0b0af415d1cb (commit)
      from  3f9daf434ab572044e4826d69dd6b7d6c963c547 (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit afa960cbbcd609123d710c301e7a9a070c1fed70
Author: Günther Deschner <gd at samba.org>
Date:   Thu Feb 5 15:50:47 2009 +0100

    spoolss: add generated spoolss code.
    
    Guenther

commit c9e64100d445b7c8c447629c0535722a8e59d1f9
Author: Günther Deschner <gd at samba.org>
Date:   Fri Nov 14 22:15:16 2008 +0100

    spoolss: fix samba4 dependency of spoolss helper.
    
    Guenther

commit b03913cbc684d3bd5e39701e103da875330f3f32
Author: Günther Deschner <gd at samba.org>
Date:   Fri Nov 14 21:43:57 2008 +0100

    spoolss: move ndr spoolss helper to main librpc dir.
    
    Guenther

commit 60fc7dadd6b9af645d5e1a8fba2f0b0af415d1cb
Author: Günther Deschner <gd at samba.org>
Date:   Thu Feb 5 13:43:18 2009 +0100

    Do not ignore spoolss anymore.
    
    Guenther

-----------------------------------------------------------------------

Summary of changes:
 .gitignore                           |    2 -
 librpc/gen_ndr/cli_spoolss.c         | 4433 +++++++++
 librpc/gen_ndr/cli_spoolss.h         |  523 ++
 librpc/gen_ndr/ndr_spoolss.c         |16993 ++++++++++++++++++++++++++++++++++
 librpc/gen_ndr/ndr_spoolss.h         |  501 +
 librpc/gen_ndr/srv_spoolss.c         | 8437 +++++++++++++++++
 librpc/gen_ndr/srv_spoolss.h         |  199 +
 librpc/idl/spoolss.idl               |    2 +-
 librpc/ndr/ndr_spoolss_buf.c         |  534 ++
 librpc/ndr/ndr_spoolss_buf.h         |   45 +
 source3/Makefile.in                  |    3 +
 source4/librpc/config.mk             |    4 +-
 source4/librpc/ndr/ndr_spoolss_buf.c |  532 --
 13 files changed, 31670 insertions(+), 538 deletions(-)
 create mode 100644 librpc/gen_ndr/cli_spoolss.c
 create mode 100644 librpc/gen_ndr/cli_spoolss.h
 create mode 100644 librpc/gen_ndr/ndr_spoolss.c
 create mode 100644 librpc/gen_ndr/ndr_spoolss.h
 create mode 100644 librpc/gen_ndr/srv_spoolss.c
 create mode 100644 librpc/gen_ndr/srv_spoolss.h
 create mode 100644 librpc/ndr/ndr_spoolss_buf.c
 create mode 100644 librpc/ndr/ndr_spoolss_buf.h
 delete mode 100644 source4/librpc/ndr/ndr_spoolss_buf.c


Changeset truncated at 500 lines:

diff --git a/.gitignore b/.gitignore
index dae5f06..703f7e3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -218,7 +218,6 @@ source4/librpc/gen_ndr
 source4/librpc/idl-deps
 source4/librpc/ndr/libndr_proto.h
 source4/librpc/ndr/ndr_compression.h
-source4/librpc/ndr/ndr_spoolss_buf.h
 source4/librpc/ndr/ndr_table.h
 source4/librpc/rpc/dcerpc_proto.h
 source4/librpc/rpc/dcerpc_table.h
@@ -318,7 +317,6 @@ librpc/gen_ndr/*wzcsvc*
 librpc/gen_ndr/*w32time*
 librpc/gen_ndr/*wmi*
 librpc/gen_ndr/*trkwks*
-librpc/gen_ndr/*_spoolss*
 librpc/gen_ndr/*rot*
 librpc/gen_ndr/*remact*
 librpc/gen_ndr/*oxidresolver*
diff --git a/librpc/gen_ndr/cli_spoolss.c b/librpc/gen_ndr/cli_spoolss.c
new file mode 100644
index 0000000..1071f2a
--- /dev/null
+++ b/librpc/gen_ndr/cli_spoolss.c
@@ -0,0 +1,4433 @@
+/*
+ * Unix SMB/CIFS implementation.
+ * client auto-generated by pidl. DO NOT MODIFY!
+ */
+
+#include "includes.h"
+#include "../librpc/gen_ndr/cli_spoolss.h"
+
+NTSTATUS rpccli_spoolss_EnumPrinters(struct rpc_pipe_client *cli,
+				     TALLOC_CTX *mem_ctx,
+				     uint32_t flags /* [in]  */,
+				     const char *server /* [in] [unique,charset(UTF16)] */,
+				     uint32_t level /* [in]  */,
+				     DATA_BLOB *buffer /* [in] [unique] */,
+				     uint32_t offered /* [in]  */,
+				     union spoolss_PrinterInfo *info /* [out] [unique,switch_is(level),size_is(count)] */,
+				     uint32_t needed /* [out]  */,
+				     uint32_t count /* [out]  */,
+				     WERROR *werror)
+{
+	struct spoolss_EnumPrinters r;
+	NTSTATUS status;
+
+	/* In parameters */
+	r.in.flags = flags;
+	r.in.server = server;
+	r.in.level = level;
+	r.in.buffer = buffer;
+	r.in.offered = offered;
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_IN_DEBUG(spoolss_EnumPrinters, &r);
+	}
+
+	status = cli->dispatch(cli,
+				mem_ctx,
+				&ndr_table_spoolss,
+				NDR_SPOOLSS_ENUMPRINTERS,
+				&r);
+
+	if (!NT_STATUS_IS_OK(status)) {
+		return status;
+	}
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_OUT_DEBUG(spoolss_EnumPrinters, &r);
+	}
+
+	if (NT_STATUS_IS_ERR(status)) {
+		return status;
+	}
+
+	/* Return variables */
+	if (info && r.out.info) {
+		memcpy(info, r.out.info, count * sizeof(*info));
+	}
+	return NT_STATUS_NOT_SUPPORTED;
+	return NT_STATUS_NOT_SUPPORTED;
+
+	/* Return result */
+	if (werror) {
+		*werror = r.out.result;
+	}
+
+	return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_spoolss_OpenPrinter(struct rpc_pipe_client *cli,
+				    TALLOC_CTX *mem_ctx,
+				    const char *printername /* [in] [unique,charset(UTF16)] */,
+				    const char *datatype /* [in] [unique,charset(UTF16)] */,
+				    struct spoolss_DevmodeContainer devmode_ctr /* [in]  */,
+				    uint32_t access_mask /* [in]  */,
+				    struct policy_handle *handle /* [out] [ref] */,
+				    WERROR *werror)
+{
+	struct spoolss_OpenPrinter r;
+	NTSTATUS status;
+
+	/* In parameters */
+	r.in.printername = printername;
+	r.in.datatype = datatype;
+	r.in.devmode_ctr = devmode_ctr;
+	r.in.access_mask = access_mask;
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_IN_DEBUG(spoolss_OpenPrinter, &r);
+	}
+
+	status = cli->dispatch(cli,
+				mem_ctx,
+				&ndr_table_spoolss,
+				NDR_SPOOLSS_OPENPRINTER,
+				&r);
+
+	if (!NT_STATUS_IS_OK(status)) {
+		return status;
+	}
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_OUT_DEBUG(spoolss_OpenPrinter, &r);
+	}
+
+	if (NT_STATUS_IS_ERR(status)) {
+		return status;
+	}
+
+	/* Return variables */
+	*handle = *r.out.handle;
+
+	/* Return result */
+	if (werror) {
+		*werror = r.out.result;
+	}
+
+	return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_spoolss_SetJob(struct rpc_pipe_client *cli,
+			       TALLOC_CTX *mem_ctx,
+			       struct policy_handle *handle /* [in] [ref] */,
+			       uint32_t job_id /* [in]  */,
+			       struct spoolss_JobInfoContainer *ctr /* [in] [unique] */,
+			       enum spoolss_JobControl command /* [in]  */,
+			       WERROR *werror)
+{
+	struct spoolss_SetJob r;
+	NTSTATUS status;
+
+	/* In parameters */
+	r.in.handle = handle;
+	r.in.job_id = job_id;
+	r.in.ctr = ctr;
+	r.in.command = command;
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_IN_DEBUG(spoolss_SetJob, &r);
+	}
+
+	status = cli->dispatch(cli,
+				mem_ctx,
+				&ndr_table_spoolss,
+				NDR_SPOOLSS_SETJOB,
+				&r);
+
+	if (!NT_STATUS_IS_OK(status)) {
+		return status;
+	}
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_OUT_DEBUG(spoolss_SetJob, &r);
+	}
+
+	if (NT_STATUS_IS_ERR(status)) {
+		return status;
+	}
+
+	/* Return variables */
+
+	/* Return result */
+	if (werror) {
+		*werror = r.out.result;
+	}
+
+	return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_spoolss_GetJob(struct rpc_pipe_client *cli,
+			       TALLOC_CTX *mem_ctx,
+			       struct policy_handle *handle /* [in] [ref] */,
+			       uint32_t job_id /* [in]  */,
+			       uint32_t level /* [in]  */,
+			       DATA_BLOB *buffer /* [in] [unique] */,
+			       uint32_t offered /* [in]  */,
+			       union spoolss_JobInfo *info /* [out] [unique,subcontext_size(offered),subcontext(4),switch_is(level)] */,
+			       uint32_t needed /* [out]  */,
+			       WERROR *werror)
+{
+	struct spoolss_GetJob r;
+	NTSTATUS status;
+
+	/* In parameters */
+	r.in.handle = handle;
+	r.in.job_id = job_id;
+	r.in.level = level;
+	r.in.buffer = buffer;
+	r.in.offered = offered;
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_IN_DEBUG(spoolss_GetJob, &r);
+	}
+
+	status = cli->dispatch(cli,
+				mem_ctx,
+				&ndr_table_spoolss,
+				NDR_SPOOLSS_GETJOB,
+				&r);
+
+	if (!NT_STATUS_IS_OK(status)) {
+		return status;
+	}
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_OUT_DEBUG(spoolss_GetJob, &r);
+	}
+
+	if (NT_STATUS_IS_ERR(status)) {
+		return status;
+	}
+
+	/* Return variables */
+	if (info && r.out.info) {
+		*info = *r.out.info;
+	}
+	return NT_STATUS_NOT_SUPPORTED;
+
+	/* Return result */
+	if (werror) {
+		*werror = r.out.result;
+	}
+
+	return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_spoolss_EnumJobs(struct rpc_pipe_client *cli,
+				 TALLOC_CTX *mem_ctx,
+				 struct policy_handle *handle /* [in] [ref] */,
+				 uint32_t firstjob /* [in]  */,
+				 uint32_t numjobs /* [in]  */,
+				 uint32_t level /* [in]  */,
+				 DATA_BLOB *buffer /* [in] [unique] */,
+				 uint32_t offered /* [in]  */,
+				 union spoolss_JobInfo *info /* [out] [unique,switch_is(level),size_is(count)] */,
+				 uint32_t needed /* [out]  */,
+				 uint32_t count /* [out]  */,
+				 WERROR *werror)
+{
+	struct spoolss_EnumJobs r;
+	NTSTATUS status;
+
+	/* In parameters */
+	r.in.handle = handle;
+	r.in.firstjob = firstjob;
+	r.in.numjobs = numjobs;
+	r.in.level = level;
+	r.in.buffer = buffer;
+	r.in.offered = offered;
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_IN_DEBUG(spoolss_EnumJobs, &r);
+	}
+
+	status = cli->dispatch(cli,
+				mem_ctx,
+				&ndr_table_spoolss,
+				NDR_SPOOLSS_ENUMJOBS,
+				&r);
+
+	if (!NT_STATUS_IS_OK(status)) {
+		return status;
+	}
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_OUT_DEBUG(spoolss_EnumJobs, &r);
+	}
+
+	if (NT_STATUS_IS_ERR(status)) {
+		return status;
+	}
+
+	/* Return variables */
+	if (info && r.out.info) {
+		memcpy(info, r.out.info, count * sizeof(*info));
+	}
+	return NT_STATUS_NOT_SUPPORTED;
+	return NT_STATUS_NOT_SUPPORTED;
+
+	/* Return result */
+	if (werror) {
+		*werror = r.out.result;
+	}
+
+	return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_spoolss_AddPrinter(struct rpc_pipe_client *cli,
+				   TALLOC_CTX *mem_ctx,
+				   WERROR *werror)
+{
+	struct spoolss_AddPrinter r;
+	NTSTATUS status;
+
+	/* In parameters */
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_IN_DEBUG(spoolss_AddPrinter, &r);
+	}
+
+	status = cli->dispatch(cli,
+				mem_ctx,
+				&ndr_table_spoolss,
+				NDR_SPOOLSS_ADDPRINTER,
+				&r);
+
+	if (!NT_STATUS_IS_OK(status)) {
+		return status;
+	}
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_OUT_DEBUG(spoolss_AddPrinter, &r);
+	}
+
+	if (NT_STATUS_IS_ERR(status)) {
+		return status;
+	}
+
+	/* Return variables */
+
+	/* Return result */
+	if (werror) {
+		*werror = r.out.result;
+	}
+
+	return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_spoolss_DeletePrinter(struct rpc_pipe_client *cli,
+				      TALLOC_CTX *mem_ctx,
+				      struct policy_handle *handle /* [in] [ref] */,
+				      WERROR *werror)
+{
+	struct spoolss_DeletePrinter r;
+	NTSTATUS status;
+
+	/* In parameters */
+	r.in.handle = handle;
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_IN_DEBUG(spoolss_DeletePrinter, &r);
+	}
+
+	status = cli->dispatch(cli,
+				mem_ctx,
+				&ndr_table_spoolss,
+				NDR_SPOOLSS_DELETEPRINTER,
+				&r);
+
+	if (!NT_STATUS_IS_OK(status)) {
+		return status;
+	}
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_OUT_DEBUG(spoolss_DeletePrinter, &r);
+	}
+
+	if (NT_STATUS_IS_ERR(status)) {
+		return status;
+	}
+
+	/* Return variables */
+
+	/* Return result */
+	if (werror) {
+		*werror = r.out.result;
+	}
+
+	return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_spoolss_SetPrinter(struct rpc_pipe_client *cli,
+				   TALLOC_CTX *mem_ctx,
+				   struct policy_handle *handle /* [in] [ref] */,
+				   uint32_t level /* [in]  */,
+				   union spoolss_SetPrinterInfo info /* [in] [switch_is(level)] */,
+				   struct spoolss_DevmodeContainer devmode_ctr /* [in]  */,
+				   struct sec_desc_buf secdesc_ctr /* [in]  */,
+				   enum spoolss_PrinterControl command /* [in]  */,
+				   WERROR *werror)
+{
+	struct spoolss_SetPrinter r;
+	NTSTATUS status;
+
+	/* In parameters */
+	r.in.handle = handle;
+	r.in.level = level;
+	r.in.info = info;
+	r.in.devmode_ctr = devmode_ctr;
+	r.in.secdesc_ctr = secdesc_ctr;
+	r.in.command = command;
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_IN_DEBUG(spoolss_SetPrinter, &r);
+	}
+
+	status = cli->dispatch(cli,
+				mem_ctx,
+				&ndr_table_spoolss,
+				NDR_SPOOLSS_SETPRINTER,
+				&r);
+
+	if (!NT_STATUS_IS_OK(status)) {
+		return status;
+	}
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_OUT_DEBUG(spoolss_SetPrinter, &r);
+	}
+
+	if (NT_STATUS_IS_ERR(status)) {
+		return status;
+	}
+
+	/* Return variables */
+
+	/* Return result */
+	if (werror) {
+		*werror = r.out.result;
+	}
+
+	return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_spoolss_GetPrinter(struct rpc_pipe_client *cli,
+				   TALLOC_CTX *mem_ctx,
+				   struct policy_handle *handle /* [in] [ref] */,
+				   uint32_t level /* [in]  */,
+				   DATA_BLOB *buffer /* [in] [unique] */,
+				   uint32_t offered /* [in]  */,
+				   union spoolss_PrinterInfo *info /* [out] [unique,subcontext_size(offered),subcontext(4),switch_is(level)] */,
+				   uint32_t needed /* [out]  */,
+				   WERROR *werror)
+{
+	struct spoolss_GetPrinter r;
+	NTSTATUS status;
+
+	/* In parameters */
+	r.in.handle = handle;
+	r.in.level = level;
+	r.in.buffer = buffer;
+	r.in.offered = offered;
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_IN_DEBUG(spoolss_GetPrinter, &r);
+	}
+
+	status = cli->dispatch(cli,
+				mem_ctx,
+				&ndr_table_spoolss,
+				NDR_SPOOLSS_GETPRINTER,
+				&r);
+
+	if (!NT_STATUS_IS_OK(status)) {
+		return status;
+	}
+
+	if (DEBUGLEVEL >= 10) {
+		NDR_PRINT_OUT_DEBUG(spoolss_GetPrinter, &r);
+	}
+
+	if (NT_STATUS_IS_ERR(status)) {
+		return status;
+	}
+
+	/* Return variables */
+	if (info && r.out.info) {
+		*info = *r.out.info;
+	}
+	return NT_STATUS_NOT_SUPPORTED;
+
+	/* Return result */
+	if (werror) {
+		*werror = r.out.result;
+	}
+


-- 
Samba Shared Repository


More information about the samba-cvs mailing list