The Samba-Bugzilla – Attachment 17320 Details for
Bug 15081
The samba background daemon doesn't refresh the printcap cache on startup
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch for 4.16
samba-4.16-fix-bgqd.patch (text/plain), 2.32 KB, created by
Andreas Schneider
on 2022-06-07 08:30:27 UTC
(
hide
)
Description:
patch for 4.16
Filename:
MIME Type:
Creator:
Andreas Schneider
Created:
2022-06-07 08:30:27 UTC
Size:
2.32 KB
patch
obsolete
>From d45dc3abb0dfb9f4c71984028f38b607571c4199 Mon Sep 17 00:00:00 2001 >From: Andreas Schneider <asn@samba.org> >Date: Mon, 30 May 2022 17:22:21 +0200 >Subject: [PATCH 1/2] 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) >--- > source3/printing/queue_process.c | 3 +++ > 1 file changed, 3 insertions(+) > >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; >-- >2.36.1 > > >From 18666097f2278663c8f6b4997acf361149c4fb91 Mon Sep 17 00:00:00 2001 >From: Andreas Schneider <asn@samba.org> >Date: Tue, 31 May 2022 08:35:00 +0200 >Subject: [PATCH 2/2] s3:printing: Start samba-bgqd as soon as possible > >We need some time to fill the printcap cache. > >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 ac16351ff5a0c5b46f461c26516b85e8483bba83) >--- > source3/printing/queue_process.c | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) > >diff --git a/source3/printing/queue_process.c b/source3/printing/queue_process.c >index c44f60fa20e..6613e8f9f55 100644 >--- a/source3/printing/queue_process.c >+++ b/source3/printing/queue_process.c >@@ -423,16 +423,16 @@ bool printing_subsystem_init(struct tevent_context *ev_ctx, > { > pid_t pid = -1; > >- if (!print_backend_init(msg_ctx)) { >- return false; >- } >- > pid = start_background_queue(NULL, NULL, NULL); > if (pid == -1) { > return false; > } > background_lpq_updater_pid = pid; > >+ if (!print_backend_init(msg_ctx)) { >+ return false; >+ } >+ > return true; > } > >-- >2.36.1 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Flags:
jra
:
review+
Actions:
View
Attachments on
bug 15081
: 17320