1
0
mirror of https://github.com/samba-team/samba.git synced 2025-03-29 02:50:28 +03:00

printing: remove unused arguments from load_printers()

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
Stefan Metzmacher 2018-05-23 16:35:20 +02:00
parent d33c355103
commit 72bd6885ab
5 changed files with 9 additions and 15 deletions

View File

@ -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));

View File

@ -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_ */

View File

@ -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.

View File

@ -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);

View File

@ -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);
}