ctdb-event: Only run talloc report if CTDB_INTERACTIVE is set
authorMartin Schwenke <martin@meltin.net>
Fri, 19 Oct 2018 06:27:15 +0000 (17:27 +1100)
committerAmitay Isaacs <amitay@samba.org>
Tue, 6 Nov 2018 06:16:15 +0000 (07:16 +0100)
This is only really wanted for interactive testing when logging to
stderr.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
ctdb/event/event_daemon.c

index 96b41a874e8bbdcda71c364b260198bfa12a5666..3f9827c6a069a0af99b590514a1d637118f28f2d 100644 (file)
@@ -361,7 +361,7 @@ int main(int argc, const char **argv)
                ret = 0;
        }
 
-       if (getenv("CTDB_TEST_MODE") != NULL) {
+       if (t != NULL) {
                talloc_report_full(e_state->mem_ctx, stderr);
        }