summaryrefslogtreecommitdiff
path: root/source3/printing
diff options
context:
space:
mode:
Diffstat (limited to 'source3/printing')
-rw-r--r--source3/printing/queue_process.c12
-rw-r--r--source3/printing/queue_process.h3
2 files changed, 12 insertions, 3 deletions
diff --git a/source3/printing/queue_process.c b/source3/printing/queue_process.c
index 5d18a08d63..82fd70d36d 100644
--- a/source3/printing/queue_process.c
+++ b/source3/printing/queue_process.c
@@ -295,9 +295,17 @@ bool printing_subsystem_init(struct tevent_context *ev_ctx,
}
void printing_subsystem_update(struct tevent_context *ev_ctx,
- struct messaging_context *msg_ctx)
+ struct messaging_context *msg_ctx,
+ bool force)
{
- if (background_lpq_updater_pid != -1) return;
+ if (background_lpq_updater_pid != -1) {
+ if (force) {
+ /* Send a sighup to the background process.
+ * this will force it to reload printers */
+ kill(background_lpq_updater_pid, SIGHUP);
+ }
+ return;
+ }
pcap_cache_reload(ev_ctx, msg_ctx, &reload_pcap_change_notify);
}
diff --git a/source3/printing/queue_process.h b/source3/printing/queue_process.h
index f0da726058..5f282c4462 100644
--- a/source3/printing/queue_process.h
+++ b/source3/printing/queue_process.h
@@ -25,6 +25,7 @@ bool printing_subsystem_init(struct tevent_context *ev_ctx,
bool start_daemons,
bool background_queue);
void printing_subsystem_update(struct tevent_context *ev_ctx,
- struct messaging_context *msg_ctx);
+ struct messaging_context *msg_ctx,
+ bool force);
pid_t start_background_queue(struct tevent_context *ev,
struct messaging_context *msg);