diff options
author | Costa Tsaousis <costa@netdata.cloud> | 2022-06-02 00:59:18 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-02 00:59:18 +0300 |
commit | 228a2d0aea0209adde50ff92c9801dcb8fb8fbea (patch) | |
tree | 5e8e69a87e16ec3979830e079d6c3dcb8420df61 /libnetdata | |
parent | 81832edce2b2c0cb8a76ae1d69b99086c974005c (diff) |
Fix dictionary crash walkthrough empty (#13051)
fix dictionary walkthrouhg crash when the dictionary is empty
Diffstat (limited to 'libnetdata')
-rw-r--r-- | libnetdata/dictionary/dictionary.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libnetdata/dictionary/dictionary.c b/libnetdata/dictionary/dictionary.c index bc1e872cbd..de182cb023 100644 --- a/libnetdata/dictionary/dictionary.c +++ b/libnetdata/dictionary/dictionary.c @@ -902,7 +902,7 @@ int dictionary_walkthrough_rw(DICTIONARY *dict, char rw, int (*callback)(const c // written in such a way, that the callback can delete the active element int ret = 0; - NAME_VALUE *nv = dict->first_item, *nv_next = nv->next; + NAME_VALUE *nv = dict->first_item, *nv_next; while(nv) { nv_next = nv->next; |