refactor: drop dead filter_rules_apply, unify set_error, dedup path_is_within

This commit is contained in:
2026-09-21 21:09:05 +02:00
parent 0669335ca5
commit 134dcd74cc
9 changed files with 37 additions and 63 deletions
+1 -9
View File
@@ -6,7 +6,6 @@
#include <errno.h>
#include <limits.h>
#include <netinet/in.h>
#include <stdarg.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
@@ -17,14 +16,7 @@
/* helpers */
/* ------------------------------------------------------------------ */
static void set_error(char* err, size_t err_size, const char* fmt, ...) {
if (!err || err_size == 0)
return;
va_list args;
va_start(args, fmt);
vsnprintf(err, err_size, fmt, args);
va_end(args);
}
#define set_error utils_set_error
/* Trim leading and trailing ASCII space/tab in place; returns the new start. */
static char* trim_ws(char* s) {