mirror of
https://github.com/moparisthebest/hexchat
synced 2024-12-23 16:18:52 -05:00
fix some memory leaks
This commit is contained in:
parent
14c7027d52
commit
e2fa2d4787
@ -1698,6 +1698,7 @@ xchat_get_plugin_pref (xchat_plugin *pl, char *var, char *dest)
|
||||
|
||||
if (!cfg)
|
||||
{
|
||||
close (fh);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -1711,6 +1712,8 @@ xchat_get_plugin_pref (xchat_plugin *pl, char *var, char *dest)
|
||||
|
||||
if (!cfg_get_str (cfg, var, dest, 512)) /* dest_len is the same as buffer size in set */
|
||||
{
|
||||
free (cfg);
|
||||
close (fh);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user