# HG changeset patch # User Kim Alvefur # Date 1374695438 -7200 # Node ID 767e29b2cd3afc6bf0a60a22810964450a2dd60c # Parent 61521ce49aae6c62a871203a15f77f295edb7145# Parent ebc0749181735c205fdd09d9bba1419378dd038b Merge 0.9->trunk diff -r 61521ce49aae -r 767e29b2cd3a plugins/adhoc/adhoc.lib.lua --- a/plugins/adhoc/adhoc.lib.lua Mon Jul 22 20:29:41 2013 +0200 +++ b/plugins/adhoc/adhoc.lib.lua Wed Jul 24 21:50:38 2013 +0200 @@ -34,7 +34,6 @@ local data, state = command:handler(dataIn, states[sessionid]); states[sessionid] = state; - local stanza = st.reply(stanza); local cmdtag; if data.status == "completed" then states[sessionid] = nil; @@ -44,8 +43,8 @@ cmdtag = command:cmdtag("canceled", sessionid); elseif data.status == "error" then states[sessionid] = nil; - stanza = st.error_reply(stanza, data.error.type, data.error.condition, data.error.message); - origin.send(stanza); + local reply = st.error_reply(stanza, data.error.type, data.error.condition, data.error.message); + origin.send(reply); return true; else cmdtag = command:cmdtag("executing", sessionid); @@ -78,8 +77,9 @@ cmdtag:add_child(content); end end - stanza:add_child(cmdtag); - origin.send(stanza); + local reply = st.reply(stanza); + reply:add_child(cmdtag); + origin.send(reply); return true; end diff -r 61521ce49aae -r 767e29b2cd3a plugins/mod_c2s.lua --- a/plugins/mod_c2s.lua Mon Jul 22 20:29:41 2013 +0200 +++ b/plugins/mod_c2s.lua Wed Jul 24 21:50:38 2013 +0200 @@ -25,7 +25,7 @@ local c2s_timeout = module:get_option_number("c2s_timeout"); local stream_close_timeout = module:get_option_number("c2s_close_timeout", 5); -local opt_keepalives = module:get_option_boolean("tcp_keepalives", false); +local opt_keepalives = module:get_option_boolean("c2s_tcp_keepalives", module:get_option_boolean("tcp_keepalives", true)); local sessions = module:shared("sessions"); local core_process_stanza = prosody.core_process_stanza;