1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-27 05:16:38 +02:00

api: fix memory leak in function string_dyn_free()

Bug was introduced by commit af138840b3.
This commit is contained in:
Sébastien Helleu
2017-04-02 08:39:29 +02:00
parent 20bb762e28
commit c652598ad7
+5 -3
View File
@@ -3453,10 +3453,12 @@ string_dyn_free (char **string, int free_string)
if (free_string)
{
free (ptr_string_dyn->string);
return NULL;
ptr_string = NULL;
}
else
{
ptr_string = ptr_string_dyn->string;
}
ptr_string = ptr_string_dyn->string;
free (ptr_string_dyn);