summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2010-08-08 17:11:23 +0200
committerVolker Lendecke <vl@samba.org>2010-08-08 18:09:37 +0200
commitde108248729cbed4464f0fb68b6f4b2d2bbdcc1e (patch)
tree03f24ee42a188198d0ff9d65f832929bf9a1250e /source3
parent3b5b74c7dd931815e7b3763ad1cbf47c3710f60d (diff)
downloadsamba-de108248729cbed4464f0fb68b6f4b2d2bbdcc1e.tar.gz
samba-de108248729cbed4464f0fb68b6f4b2d2bbdcc1e.tar.bz2
samba-de108248729cbed4464f0fb68b6f4b2d2bbdcc1e.zip
s3: Lift the server_messaging_context from print_job_set_name
Diffstat (limited to 'source3')
-rw-r--r--source3/include/printing.h4
-rw-r--r--source3/printing/printing.c7
-rw-r--r--source3/rpc_server/srv_spoolss_nt.c4
3 files changed, 10 insertions, 5 deletions
diff --git a/source3/include/printing.h b/source3/include/printing.h
index 3921b7c8fc..66fdda6a59 100644
--- a/source3/include/printing.h
+++ b/source3/include/printing.h
@@ -121,7 +121,9 @@ bool print_notify_deregister_pid(int snum);
bool print_job_exists(const char* sharename, uint32 jobid);
char *print_job_fname(const char* sharename, uint32 jobid);
struct spoolss_DeviceMode *print_job_devmode(const char* sharename, uint32 jobid);
-bool print_job_set_name(const char *sharename, uint32 jobid, const char *name);
+bool print_job_set_name(struct tevent_context *ev,
+ struct messaging_context *msg_ctx,
+ const char *sharename, uint32 jobid, const char *name);
bool print_job_get_name(TALLOC_CTX *mem_ctx, const char *sharename, uint32_t jobid, char **name);
WERROR print_job_delete(struct auth_serversupplied_info *server_info,
struct messaging_context *msg_ctx,
diff --git a/source3/printing/printing.c b/source3/printing/printing.c
index fe87b9bf6c..ff1394f028 100644
--- a/source3/printing/printing.c
+++ b/source3/printing/printing.c
@@ -1974,7 +1974,9 @@ struct spoolss_DeviceMode *print_job_devmode(const char* sharename, uint32 jobid
Set the name of a job. Only possible for owner.
****************************************************************************/
-bool print_job_set_name(const char *sharename, uint32 jobid, const char *name)
+bool print_job_set_name(struct tevent_context *ev,
+ struct messaging_context *msg_ctx,
+ const char *sharename, uint32 jobid, const char *name)
{
struct printjob *pjob;
@@ -1983,8 +1985,7 @@ bool print_job_set_name(const char *sharename, uint32 jobid, const char *name)
return False;
fstrcpy(pjob->jobname, name);
- return pjob_store(server_event_context(), server_messaging_context(),
- sharename, jobid, pjob);
+ return pjob_store(ev, msg_ctx, sharename, jobid, pjob);
}
/****************************************************************************
diff --git a/source3/rpc_server/srv_spoolss_nt.c b/source3/rpc_server/srv_spoolss_nt.c
index 82d1795869..dd283caf46 100644
--- a/source3/rpc_server/srv_spoolss_nt.c
+++ b/source3/rpc_server/srv_spoolss_nt.c
@@ -6671,7 +6671,9 @@ static WERROR spoolss_setjob_1(TALLOC_CTX *mem_ctx,
return WERR_OK;
}
- if (!print_job_set_name(printer_name, job_id, r->document_name)) {
+ if (!print_job_set_name(server_event_context(),
+ server_messaging_context(),
+ printer_name, job_id, r->document_name)) {
return WERR_BADFID;
}