diff options
author | Timo Sirainen <cras@irssi.org> | 2000-10-01 22:12:01 +0000 |
---|---|---|
committer | cras <cras@dbcabf3a-b0e7-0310-adc4-f8d773084564> | 2000-10-01 22:12:01 +0000 |
commit | 0158782b02765bf7eadd8b56c9d71783acf5e802 (patch) | |
tree | 9c09d98f54cf77e0ad348b08bddd3d43ea9fd66e /src/core | |
parent | f8ea75ceb144fd7efaf0c582f10d06a05420235f (diff) | |
download | irssi-0158782b02765bf7eadd8b56c9d71783acf5e802.zip |
Keyboard should never get stuck again when receiving huge amounts of
text from server that irssi doesn't handle fast enough.
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@710 dbcabf3a-b0e7-0310-adc4-f8d773084564
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/misc.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/core/misc.c b/src/core/misc.c index 2f7d8049..4cdcf4de 100644 --- a/src/core/misc.c +++ b/src/core/misc.c @@ -58,8 +58,8 @@ static int irssi_io_invoke(GIOChannel *source, GIOCondition condition, return TRUE; } -int g_input_add(int source, GInputCondition condition, - GInputFunction function, void *data) +int g_input_add_full(int source, int priority, GInputCondition condition, + GInputFunction function, void *data) { IRSSI_INPUT_REC *rec; unsigned int result; @@ -78,13 +78,20 @@ int g_input_add(int source, GInputCondition condition, cond |= G_IO_OUT; channel = g_io_channel_unix_new (source); - result = g_io_add_watch_full(channel, G_PRIORITY_DEFAULT, cond, + result = g_io_add_watch_full(channel, priority, cond, irssi_io_invoke, rec, g_free); g_io_channel_unref(channel); return result; } +int g_input_add(int source, GInputCondition condition, + GInputFunction function, void *data) +{ + return g_input_add_full(source, G_PRIORITY_DEFAULT, condition, + function, data); +} + long get_timeval_diff(const GTimeVal *tv1, const GTimeVal *tv2) { long secs, usecs; |