From ec798bdeb23783b72a2476eacfad63066d3bae3b Mon Sep 17 00:00:00 2001 From: William Casarin Date: Mon, 13 Jan 2025 11:06:09 -0800 Subject: [PATCH] nostrdb: debug: fix debug logs We forgot to move one DEBUG instance to NDB_LOG Fixes: b4c2ff3d270a ("Only log to stdout if NDB_LOG is defined") Signed-off-by: William Casarin --- nostrdb/src/nostrdb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nostrdb/src/nostrdb.c b/nostrdb/src/nostrdb.c index b499fe02..87ed65c7 100644 --- a/nostrdb/src/nostrdb.c +++ b/nostrdb/src/nostrdb.c @@ -575,7 +575,7 @@ int ndb_filter_clone(struct ndb_filter *dst, struct ndb_filter *src) // are as small as possible. This also prevents new fields from being added int ndb_filter_end(struct ndb_filter *filter) { -#ifdef DEBUG +#ifdef NDB_LOG size_t orig_size; #endif size_t data_len, elem_len; @@ -586,7 +586,7 @@ int ndb_filter_end(struct ndb_filter *filter) // all of the element pointers accordingly data_len = filter->data_buf.p - filter->data_buf.start; elem_len = filter->elem_buf.p - filter->elem_buf.start; -#ifdef DEBUG +#ifdef NDB_LOG orig_size = filter->data_buf.end - filter->elem_buf.start; #endif