summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2018-05-23 16:35:20 +0200
committerStefan Metzmacher <metze@samba.org>2018-06-14 20:52:20 +0200
commit72bd6885ab18c920c6ed9e76946fd809e70e2abf (patch)
treef9ef7b6f7a6ef997b6df04e2227e8ab10656963c /source3
parentd33c355103406ceb4941a479f34ea33eae8e87a7 (diff)
downloadsamba-72bd6885ab18c920c6ed9e76946fd809e70e2abf.tar.gz
printing: remove unused arguments from load_printers()
Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
Diffstat (limited to 'source3')
-rw-r--r--source3/printing/load.c3
-rw-r--r--source3/printing/load.h3
-rw-r--r--source3/printing/queue_process.c2
-rw-r--r--source3/printing/spoolssd.c12
-rw-r--r--source3/smbd/server_reload.c4
5 files changed, 9 insertions, 15 deletions
diff --git a/source3/printing/load.c b/source3/printing/load.c
index 238998d920d..51495f970db 100644
--- a/source3/printing/load.c
+++ b/source3/printing/load.c
@@ -62,8 +62,7 @@ static void add_auto_printers(void)
/***************************************************************************
load automatic printer services from pre-populated pcap cache
***************************************************************************/
-void load_printers(struct tevent_context *ev,
- struct messaging_context *msg_ctx)
+void load_printers(void)
{
SMB_ASSERT(pcap_cache_loaded(NULL));
diff --git a/source3/printing/load.h b/source3/printing/load.h
index 4611e9748c2..36e0a25a7dd 100644
--- a/source3/printing/load.h
+++ b/source3/printing/load.h
@@ -22,7 +22,6 @@
/* The following definitions come from printing/load.c */
-void load_printers(struct tevent_context *ev,
- struct messaging_context *msg_ctx);
+void load_printers(void);
#endif /* _PRINTING_LOAD_H_ */
diff --git a/source3/printing/queue_process.c b/source3/printing/queue_process.c
index c4941d84ccd..76fd9349fb4 100644
--- a/source3/printing/queue_process.c
+++ b/source3/printing/queue_process.c
@@ -484,7 +484,7 @@ void printing_subsystem_update(struct tevent_context *ev_ctx,
{
if (background_lpq_updater_pid != -1) {
if (pcap_cache_loaded(NULL)) {
- load_printers(ev_ctx, msg_ctx);
+ load_printers();
}
if (force) {
/* Send a sighup to the background process.
diff --git a/source3/printing/spoolssd.c b/source3/printing/spoolssd.c
index 2b08d580f35..ca1eda91879 100644
--- a/source3/printing/spoolssd.c
+++ b/source3/printing/spoolssd.c
@@ -105,7 +105,7 @@ static void update_conf(struct tevent_context *ev,
{
change_to_root_user();
lp_load_global(get_dyn_CONFIGFILE());
- load_printers(ev, msg);
+ load_printers();
spoolss_reopen_logs(spoolss_child_id);
if (spoolss_child_id == 0) {
@@ -212,13 +212,9 @@ static void spoolss_chld_sig_hup_handler(struct tevent_context *ev,
void *siginfo,
void *pvt)
{
- struct messaging_context *msg_ctx;
-
- msg_ctx = talloc_get_type_abort(pvt, struct messaging_context);
-
change_to_root_user();
DEBUG(1,("Reloading printers after SIGHUP\n"));
- load_printers(ev, msg_ctx);
+ load_printers();
spoolss_reopen_logs(spoolss_child_id);
}
@@ -293,7 +289,7 @@ static bool spoolss_child_init(struct tevent_context *ev_ctx,
* ourselves. If pcap has not been loaded yet, then ignore, we will get
* a message as soon as the bq process completes the reload. */
if (pcap_cache_loaded(NULL)) {
- load_printers(ev_ctx, msg_ctx);
+ load_printers();
}
/* try to reinit rpc queues */
@@ -704,7 +700,7 @@ pid_t start_spoolssd(struct tevent_context *ev_ctx,
* client enumeration anyway.
*/
if (pcap_cache_loaded(NULL)) {
- load_printers(ev_ctx, msg_ctx);
+ load_printers();
}
mem_ctx = talloc_new(NULL);
diff --git a/source3/smbd/server_reload.c b/source3/smbd/server_reload.c
index 9b6209619c3..f07ad925472 100644
--- a/source3/smbd/server_reload.c
+++ b/source3/smbd/server_reload.c
@@ -79,7 +79,7 @@ void delete_and_reload_printers(struct tevent_context *ev,
reload_last_pcap_time = pcap_last_update;
/* Get pcap printers updated */
- load_printers(ev, msg_ctx);
+ load_printers();
n_services = lp_numservices();
pnum = lp_servicenumber(PRINTERS_NAME);
@@ -110,7 +110,7 @@ void delete_and_reload_printers(struct tevent_context *ev,
}
/* Make sure deleted printers are gone */
- load_printers(ev, msg_ctx);
+ load_printers();
talloc_free(frame);
}