From: Eric Leblond Date: Sun, 18 May 2025 16:19:09 +0000 (+0200) Subject: datajson: use more broadly supported formatter X-Git-Tag: suricata-8.0.0-rc1~47 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d57e8731bd4cf3a1ea3ef06de4499944f05438fb;p=thirdparty%2Fsuricata.git datajson: use more broadly supported formatter --- diff --git a/src/datasets-context-json.c b/src/datasets-context-json.c index 0317fd8304..8a36939444 100644 --- a/src/datasets-context-json.c +++ b/src/datasets-context-json.c @@ -653,7 +653,7 @@ Dataset *DatajsonGet(const char *name, enum DatasetTypes type, const char *load, if (ret == 1) { SCLogDebug("dataset %s already exists", name); if (set->remove_key != remove_key) { - SCLogError("dataset %s remove_key mismatch: %b != %b", set->name, set->remove_key, + SCLogError("dataset %s remove_key mismatch: %d != %d", set->name, set->remove_key, remove_key); DatasetUnlock(); return NULL; diff --git a/src/detect-dataset.c b/src/detect-dataset.c index 5c30db3c08..41580c7a21 100644 --- a/src/detect-dataset.c +++ b/src/detect-dataset.c @@ -76,7 +76,7 @@ static int DetectDatajsonBufferMatch(DetectEngineThreadCtx *det_ctx, const Detec case DETECT_DATASET_CMD_ISSET: { // PrintRawDataFp(stdout, data, data_len); DataJsonResultType r = DatajsonLookup(sd->set, data, data_len); - SCLogDebug("r found: %d, len: %zu", r.found, r.json.len); + SCLogDebug("r found: %d, len: %u", r.found, r.json.len); if (!r.found) return 0; if (r.json.len > 0) { @@ -96,7 +96,7 @@ static int DetectDatajsonBufferMatch(DetectEngineThreadCtx *det_ctx, const Detec case DETECT_DATASET_CMD_ISNOTSET: { // PrintRawDataFp(stdout, data, data_len); DataJsonResultType r = DatajsonLookup(sd->set, data, data_len); - SCLogDebug("r found: %d, len: %zu", r.found, r.json.len); + SCLogDebug("r found: %d, len: %u", r.found, r.json.len); if (r.found) return 0; return 1;