From f181dca67d62e1bf68eb703e97bf0f9f6190c892 Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Sat, 9 Mar 2002 09:25:06 +0000 Subject: [PATCH] Fixed a memory leak with ^Y git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2540 dbcabf3a-b0e7-0310-adc4-f8d773084564 --- src/fe-text/gui-readline.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/fe-text/gui-readline.c b/src/fe-text/gui-readline.c index 32ae7abe..46cafc18 100644 --- a/src/fe-text/gui-readline.c +++ b/src/fe-text/gui-readline.c @@ -305,8 +305,10 @@ static void key_yank_from_cutbuffer(void) char *cutbuffer; cutbuffer = gui_entry_get_cutbuffer(active_entry); - if (cutbuffer != NULL) + if (cutbuffer != NULL) { gui_entry_insert_text(active_entry, cutbuffer); + g_free(cutbuffer); + } } static void key_transpose_characters(void)