summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2010-09-10 16:06:24 +0200
committerAndreas Schneider <asn@samba.org>2010-09-10 16:10:46 +0200
commitfc1a5dbffb1330bba0e4deebdf18b812ccc1a823 (patch)
treecfb707a2eb7e8f2eaa2fa050d1d3c6c7735b7f9d /source3/smbd
parented2c06f9da0401fb95dcc16b4d3a3bd4f27b09f2 (diff)
downloadsamba-fc1a5dbffb1330bba0e4deebdf18b812ccc1a823.tar.gz
samba-fc1a5dbffb1330bba0e4deebdf18b812ccc1a823.tar.bz2
samba-fc1a5dbffb1330bba0e4deebdf18b812ccc1a823.zip
s3-spoolss: Don't leak memory on the session counter list.
Thanks Günther, please check.
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/server.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/source3/smbd/server.c b/source3/smbd/server.c
index c9ae742b99..247cbb84d5 100644
--- a/source3/smbd/server.c
+++ b/source3/smbd/server.c
@@ -807,6 +807,13 @@ static bool spoolss_init_cb(void *ptr)
return nt_printing_tdb_migrate(msg_ctx);
}
+static bool spoolss_shutdown_cb(void *ptr)
+{
+ srv_spoolss_cleanup();
+
+ return true;
+}
+
/****************************************************************************
main program.
****************************************************************************/
@@ -1165,7 +1172,7 @@ extern void build_options(bool screen);
* can't register it twice.
*/
spoolss_cb.init = spoolss_init_cb;
- spoolss_cb.shutdown = NULL;
+ spoolss_cb.shutdown = spoolss_shutdown_cb;
spoolss_cb.private_data = smbd_server_conn->msg_ctx;
/* Spoolss depends on a winreg pipe, so start it first. */