commit | 234a91fbd03d800812ee51d0f5712ecb534c8f47 | [log] [tgz] |
---|---|---|
author | David Sedlák <xsedla1d@stud.fit.vutbr.cz> | Thu Aug 15 13:16:43 2019 +0200 |
committer | David Sedlák <xsedla1d@stud.fit.vutbr.cz> | Thu Aug 15 13:16:43 2019 +0200 |
tree | e45b9ce76477bb71e96ef9fb2d490973a8d07363 | |
parent | bf8a2b7ebc858875037e967959d3ee2cebbeeb45 [diff] [blame] |
dictionary BUGFIX free inserted value in all error cases if zerocopy version is used
diff --git a/src/hash_table.c b/src/hash_table.c index f26d04c..2d9af2a 100644 --- a/src/hash_table.c +++ b/src/hash_table.c
@@ -206,6 +206,9 @@ } else { /* lyht_insert returned error */ LOGINT(ctx); + if (zerocopy) { + free(value); + } return NULL; }