diff options
Diffstat (limited to 'src/include')
-rw-r--r-- | src/include/skalibs/bigkv.h | 7 | ||||
-rw-r--r-- | src/include/skalibs/bytestr.h | 2 |
2 files changed, 5 insertions, 4 deletions
diff --git a/src/include/skalibs/bigkv.h b/src/include/skalibs/bigkv.h index a5b06c2..1b6229b 100644 --- a/src/include/skalibs/bigkv.h +++ b/src/include/skalibs/bigkv.h @@ -32,9 +32,10 @@ extern bigkv_t const bigkv_zero ; #define bigkv_len(b) avltree_len(&(b)->map) -extern int bigkv_init (bigkv_t *, char const *const *, char, char const *, char const *, uint32_t) ; -#define bigkv_init_argv(b, argv) bigkv_init(b, (argv), '=', "--", "--", 0) -#define bigkv_init_envp(b, envp) bigkv_init(b, (envp), '=', 0, 0, 0) +#define bigkv_init(b) (*(b) = bigkv_zero) +extern int bigkv_fill (bigkv_t *, char const *const *, char, char const *, char const *, uint32_t) ; +#define bigkv_fill_argv(b, argv) bigkv_fill(b, (argv), '=', "--", "--", 0) +#define bigkv_fill_envp(b, envp) bigkv_fill(b, (envp), '=', 0, 0, 0) extern char const *bigkv_search (bigkv_t const *, char const *) ; extern void bigkv_free (bigkv_t *) ; diff --git a/src/include/skalibs/bytestr.h b/src/include/skalibs/bytestr.h index a0dc027..35fe8d2 100644 --- a/src/include/skalibs/bytestr.h +++ b/src/include/skalibs/bytestr.h @@ -46,7 +46,7 @@ extern void case_uppers (char *) ; extern void case_upperb (char *, size_t) ; #define case_diffb(a, n, b) case_diffn(a, (b), n) #define case_equals(a, b) (!strcasecmp(a, b)) -#define case_equalb(a, n, b) (!strcasecmp(a, (b), n)) +#define case_equalb(a, n, b) (!strncasecmp(a, (b), n)) #define case_starts(s, t) case_startb(s, strlen(s), t) extern int case_startb (char const *, size_t, char const *) gccattr_pure ; extern size_t case_str (char const *, char const *) gccattr_pure ; |