1
0
mirror of https://github.com/moparisthebest/hexchat synced 2024-12-18 05:42:19 -05:00

Only g_free() if we g_malloc() with strip_color()

This commit is contained in:
Berke Viktor 2012-07-20 18:45:12 +02:00
parent 1edd920362
commit 78cc4adfed

View File

@ -385,8 +385,11 @@ scrollback_load (session *sess)
} }
cleaned_text = text_replace_non_bmp (text, -1, &cleaned_len); cleaned_text = text_replace_non_bmp (text, -1, &cleaned_len);
if (cleaned_text != NULL) if (cleaned_text != NULL)
{
if (prefs.text_replay_strip_color)
{ {
g_free (text); g_free (text);
}
text = cleaned_text; text = cleaned_text;
} }
fe_print_text (sess, text, stamp); fe_print_text (sess, text, stamp);