Skip to content

eBPF-based security platform

status: add the eventlog to the JSON size instead of replacing it

Daniel Borkmannc1482b1f6994
diff --git a/builtin-status.c b/builtin-status.c
index 5199efd9..816e766e 100644
--- a/builtin-status.c
+++ b/builtin-status.c
@@ -714,7 +714,7 @@ int cmd_status(int argc, const char **argv)
json_cap = 16384 + (size_t)n_ups *
(6 * sizeof(struct shirudo_upatch_table_row) + 256);
if (include_eventlog && ev_rc == 0)
- json_cap = 65536 + 3 * (size_t)ev_bytes;
+ json_cap += 65536 + 3 * (size_t)ev_bytes;
if (include_kernel_log)
json_cap += (size_t)kernel_log_lines * 1024 + 4096;
if (include_modules)