diff options
| author | Patrick Steinhardt <ps@pks.im> | 2017-01-25 15:31:12 +0100 |
|---|---|---|
| committer | Patrick Steinhardt <ps@pks.im> | 2017-02-17 11:41:06 +0100 |
| commit | f31cb45ad2ca46cc743dfadf5ac8b916cbe4ea9c (patch) | |
| tree | ed98640b9181f3cfae95e63711ca7200c7e7be3d /src/strmap.h | |
| parent | a8cd560b10149208aabcfe515b2e1b6c5be6388f (diff) | |
| download | libgit2-f31cb45ad2ca46cc743dfadf5ac8b916cbe4ea9c.tar.gz | |
khash: avoid using `kh_put` directly
Diffstat (limited to 'src/strmap.h')
| -rw-r--r-- | src/strmap.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/strmap.h b/src/strmap.h index 9fdab95bb..4c5f888ae 100644 --- a/src/strmap.h +++ b/src/strmap.h @@ -42,6 +42,8 @@ typedef khiter_t git_strmap_iter; #define git_strmap_set_value_at(h, idx, v) kh_val(h, idx) = v #define git_strmap_delete_at(h, idx) kh_del(str, h, idx) +#define git_strmap_put(h, k, err) kh_put(str, h, k, err) + #define git_strmap_insert(h, key, val, rval) do { \ khiter_t __pos = kh_put(str, h, key, &rval); \ if (rval >= 0) { \ |
