From bfd185ac49ee40eb9ef304e03581b1e328b15336 Mon Sep 17 00:00:00 2001 From: Daniel Silverstone Date: Sun, 23 Feb 2020 09:19:51 +0000 Subject: dukky: Guard pointless work for deep debug Signed-off-by: Daniel Silverstone --- content/handlers/javascript/duktape/dukky.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'content') diff --git a/content/handlers/javascript/duktape/dukky.c b/content/handlers/javascript/duktape/dukky.c index 4d21573b0..dcbff6854 100644 --- a/content/handlers/javascript/duktape/dukky.c +++ b/content/handlers/javascript/duktape/dukky.c @@ -179,7 +179,7 @@ dukky_push_node_stacked(duk_context *ctx) /* ... node nodeptr klass nodes */ duk_pop_3(ctx); /* ... node */ - { + if (NSLOG_COMPILED_MIN_LEVEL <= NSLOG_LEVEL_DEEPDEBUG) { duk_dup(ctx, -1); const char * what = duk_safe_to_string(ctx, -1); NSLOG(dukky, DEEPDEBUG, "Created: %s", what); @@ -479,7 +479,7 @@ dukky_push_node(duk_context *ctx, struct dom_node *node) /* ... node nodes */ duk_pop(ctx); /* ... node */ - { + if (NSLOG_COMPILED_MIN_LEVEL <= NSLOG_LEVEL_DEEPDEBUG) { duk_dup(ctx, -1); const char * what = duk_safe_to_string(ctx, -1); NSLOG(dukky, DEEPDEBUG, "Found it memoised: %s", what); -- cgit v1.2.3