plugins/keepalive.lua

Sun, 06 Nov 2011 20:38:15 +0100

author
Kim Alvefur <zash@zash.se>
date
Sun, 06 Nov 2011 20:38:15 +0100
changeset 229
279c0e89c3b3
parent 206
1bf01ffcb5a3
child 250
a5ac643a7fd6
permissions
-rw-r--r--

plugins.vcard_update: Update for util.vcard changes.

function verse.plugins.keepalive(stream)
	stream.keepalive_timeout = stream.keepalive_timeout or 300;
	verse.add_task(stream.keepalive_timeout, function ()
		stream.conn:write(" ");
		return stream.keepalive_timeout;
	end);
end

mercurial