comparison mod_smacks/mod_smacks.lua @ 811:e2d940d81613

mod_smacks: Only request ack for stanzas
author Kim Alvefur <zash@zash.se>
date Mon, 10 Sep 2012 21:11:04 +0200
parents 464ed063a8f2
children 0095b74a3685
comparison
equal deleted inserted replaced
810:464ed063a8f2 811:e2d940d81613
82 end 82 end
83 83
84 queue[#queue+1] = cached_stanza; 84 queue[#queue+1] = cached_stanza;
85 end 85 end
86 local ok, err = _send(stanza); 86 local ok, err = _send(stanza);
87 if ok and #queue > max_unacked_stanzas and not session.awaiting_ack then 87 if ok and #queue > max_unacked_stanzas and not session.awaiting_ack and attr and not attr.xmlns then
88 session.awaiting_ack = true; 88 session.awaiting_ack = true;
89 return _send(st.stanza("r", sm_attr)); 89 return _send(st.stanza("r", sm_attr));
90 end 90 end
91 return ok, err; 91 return ok, err;
92 end 92 end