summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2022-05-30 17:22:21 +0200
committerJule Anger <janger@samba.org>2022-06-09 08:54:17 +0000
commit8507fa6fc7daa29746ed81578669070a32bd0427 (patch)
tree719ef89e4d039248e5dc5e23cd3929b826d0a82b
parentc3ce1fec590d95a2d848bce52b059784eeda430a (diff)
downloadsamba-8507fa6fc7daa29746ed81578669070a32bd0427.tar.gz
s3:printing: Initialize the printcap cache as soon as the bgqd starts
As soon as the background daemon starts, we need to initialize the printcap cache so that rpcd-spoolssd can serve printers. BUG: https://bugzilla.samba.org/show_bug.cgi?id=15081 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> (cherry picked from commit 3b5b80e99603e4c1d4d1080ed45bd75116a9fa8e)
-rw-r--r--source3/printing/queue_process.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source3/printing/queue_process.c b/source3/printing/queue_process.c
index 3b0ef55c3cc..c44f60fa20e 100644
--- a/source3/printing/queue_process.c
+++ b/source3/printing/queue_process.c
@@ -319,6 +319,9 @@ struct bq_state *register_printing_bq_handlers(
goto fail_free_handlers;
}
+ /* Initialize the printcap cache as soon as the daemon starts. */
+ pcap_cache_reload(state->ev, state->msg, reload_pcap_change_notify);
+
ok = printing_subsystem_queue_tasks(state);
if (!ok) {
goto fail_free_handlers;