diff options
author | Jan200101 <sentrycraft123@gmail.com> | 2022-09-10 22:44:23 +0200 |
---|---|---|
committer | Jan200101 <sentrycraft123@gmail.com> | 2022-09-10 22:44:23 +0200 |
commit | 7809edab2aab5701f7be3f278b10e030e944477e (patch) | |
tree | cb9cccf1ecdedcef47de361f912bdc97c2999cd1 /src | |
parent | 64b5a82d93aee5cdb8e0db520f3b1f223d9f2e99 (diff) | |
download | OFQT-7809edab2aab5701f7be3f278b10e030e944477e.tar.gz OFQT-7809edab2aab5701f7be3f278b10e030e944477e.zip |
move back to indexing strings forward instead of backwards
this is easier to deal
Diffstat (limited to 'src')
-rw-r--r-- | src/vdf/vdf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vdf/vdf.c b/src/vdf/vdf.c index c678e55..3b90a02 100644 --- a/src/vdf/vdf.c +++ b/src/vdf/vdf.c @@ -326,7 +326,7 @@ struct vdf_object* vdf_object_index_array_str(const struct vdf_object* o, const if (!o || !str || o->type != VDF_TYPE_ARRAY) return NULL; - for (size_t i = o->data.data_array.len-1; i >= 0; --i) + for (size_t i = 0; i < o->data.data_array.len; ++i) { struct vdf_object* k = o->data.data_array.data_value[i]; if (!strcmp(k->key, str)) |