From 4b8b385042ace68c4ec59fea81bf8b284b34c356 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCnther=20Deschner?= Date: Fri, 6 Sep 2013 18:08:23 +0200 Subject: s3-sessionid: move sessionid init call to the only function where it is needed. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Guenther Signed-off-by: Günther Deschner --- source3/utils/net_serverid.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/source3/utils/net_serverid.c b/source3/utils/net_serverid.c index 01109b9ffad..7d50ab1d9de 100644 --- a/source3/utils/net_serverid.c +++ b/source3/utils/net_serverid.c @@ -113,6 +113,11 @@ static int net_serverid_wipedbs_sessionid(struct db_record *rec, static int net_serverid_wipedbs(struct net_context *c, int argc, const char **argv) { + if (!sessionid_init()) { + d_printf("failed to open sessionid.tdb\n"); + return -1; + }; + connections_forall(net_serverid_wipedbs_conn, NULL); sessionid_traverse(net_serverid_wipedbs_sessionid, NULL); return 0; @@ -150,10 +155,5 @@ int net_serverid(struct net_context *c, int argc, const char **argv) {NULL, NULL, 0, NULL, NULL} }; - if (!sessionid_init()) { - d_printf("failed to open sessionid.tdb\n"); - return -1; - }; - return net_run_function(c, argc, argv, "net serverid", func); } -- cgit v1.2.1