mirror of
https://github.com/irssi/irssi.git
synced 2024-10-27 05:20:20 -04:00
refcount for timeouts/inputs wasn't 0 initially so it caused some memleaks.
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1842 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
b3779bc7a5
commit
8c5ac3fb24
@ -98,7 +98,7 @@ int perl_timeout_add(int msecs, const char *func, SV *data)
|
||||
{
|
||||
PERL_SOURCE_REC *rec;
|
||||
|
||||
rec = g_new(PERL_SOURCE_REC, 1);
|
||||
rec = g_new0(PERL_SOURCE_REC, 1);
|
||||
perl_source_ref(rec);
|
||||
|
||||
SvREFCNT_inc(data);
|
||||
@ -116,7 +116,7 @@ int perl_input_add(int source, int condition, const char *func, SV *data)
|
||||
PERL_SOURCE_REC *rec;
|
||||
GIOChannel *channel;
|
||||
|
||||
rec = g_new(PERL_SOURCE_REC, 1);
|
||||
rec = g_new0(PERL_SOURCE_REC, 1);
|
||||
perl_source_ref(rec);
|
||||
|
||||
SvREFCNT_inc(data);
|
||||
|
Loading…
Reference in New Issue
Block a user