summaryrefslogtreecommitdiffstats
path: root/src/adaptive_resortable_list.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/adaptive_resortable_list.c')
-rw-r--r--src/adaptive_resortable_list.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/adaptive_resortable_list.c b/src/adaptive_resortable_list.c
index f74c53eae..add1d8c96 100644
--- a/src/adaptive_resortable_list.c
+++ b/src/adaptive_resortable_list.c
@@ -2,7 +2,7 @@
// the default processor() of the ARL
// can be overwritten at arl_create()
-static inline void arl_callback_str2ull(const char *name, uint32_t hash, const char *value, void *dst) {
+inline void arl_callback_str2ull(const char *name, uint32_t hash, const char *value, void *dst) {
(void)name;
(void)hash;
@@ -11,6 +11,15 @@ static inline void arl_callback_str2ull(const char *name, uint32_t hash, const c
// fprintf(stderr, "name '%s' with hash %u and value '%s' is %llu\n", name, hash, value, *d);
}
+inline void arl_callback_str2kernel_uint_t(const char *name, uint32_t hash, const char *value, void *dst) {
+ (void)name;
+ (void)hash;
+
+ register kernel_uint_t *d = dst;
+ *d = str2kernel_uint_t(value);
+ // fprintf(stderr, "name '%s' with hash %u and value '%s' is %llu\n", name, hash, value, (unsigned long long)*d);
+}
+
// create a new ARL
ARL_BASE *arl_create(const char *name, void (*processor)(const char *, uint32_t, const char *, void *), size_t rechecks) {
ARL_BASE *base = callocz(1, sizeof(ARL_BASE));