summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2009-01-05 12:34:02 -0800
committerJeremy Allison <jra@samba.org>2009-01-05 12:34:02 -0800
commit101ef64e3181335b66524296af08f7df04391b9a (patch)
treefba0ae8296a2c09f27c01bb93126f4d47c80fd8a
parentde41f0e9a08b796873bdd319fe784b6c90e28b23 (diff)
downloadsamba-101ef64e3181335b66524296af08f7df04391b9a.tar.gz
samba-101ef64e3181335b66524296af08f7df04391b9a.tar.xz
samba-101ef64e3181335b66524296af08f7df04391b9a.zip
Attempt to fix crash seen with new CUPS async printcap loading code.
Jeremy.
-rw-r--r--source/Makefile.in2
-rw-r--r--source/printing/print_cups.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/source/Makefile.in b/source/Makefile.in
index 730e130e11e..a4944b1ad81 100644
--- a/source/Makefile.in
+++ b/source/Makefile.in
@@ -693,7 +693,7 @@ NMBD_OBJ = $(NMBD_OBJ1) $(PARAM_OBJ) $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
SWAT_OBJ1 = web/cgi.o web/diagnose.o web/startstop.o web/statuspage.o \
web/swat.o web/neg_lang.o
-SWAT_OBJ = $(SWAT_OBJ1) $(PARAM_OBJ) $(PRINTING_OBJ) $(LIBSMB_OBJ) \
+SWAT_OBJ = $(SWAT_OBJ1) $(PARAM_OBJ) $(PRINTING_OBJ) $(PRINTBASE_OBJ) $(LIBSMB_OBJ) \
$(LOCKING_OBJ) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(KRBCLIENT_OBJ) \
$(LIB_NONSMBD_OBJ) $(GROUPDB_OBJ) $(PLAINTEXT_AUTH_OBJ) \
$(POPT_LIB_OBJ) $(SMBLDAP_OBJ) $(RPC_PARSE_OBJ) $(LIBMSRPC_GEN_OBJ) $(LIBMSRPC_OBJ) \
diff --git a/source/printing/print_cups.c b/source/printing/print_cups.c
index 1bb149cc866..f3eb73c4009 100644
--- a/source/printing/print_cups.c
+++ b/source/printing/print_cups.c
@@ -388,6 +388,8 @@ static bool cups_pcap_load_async(int *pfd)
}
/* Child. */
+ close_all_print_db();
+
if (!reinit_after_fork(smbd_messaging_context(), true)) {
DEBUG(0,("cups_pcap_load_async: reinit_after_fork() failed\n"));
smb_panic("cups_pcap_load_async: reinit_after_fork() failed");