1
0
Fork 0

Correctly free manual "small vector" in cluster_client %-)

hotfix-1.1.0
Vitaliy Filippov 2023-10-26 22:57:27 +03:00
parent ad30b11519
commit 9336ee5476
1 changed files with 4 additions and 0 deletions

View File

@ -193,6 +193,10 @@ void cluster_client_t::inc_wait(uint64_t opcode, uint64_t flags, cluster_op_t *n
bh_op_max *= 2;
cluster_op_t **n = (cluster_op_t**)malloc_or_die(sizeof(cluster_op_t*) * bh_op_max);
memcpy(n, bh_ops, sizeof(cluster_op_t*) * bh_op_count);
if (bh_ops != bh_ops_local)
{
free(bh_ops);
}
bh_ops = n;
}
bh_ops[bh_op_count++] = next;