Software /
code /
prosody
Comparison
plugins/mod_bosh.lua @ 8491:f134be08a499
mod_bosh: Rename variable to avoid name clash [luacheck]
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Wed, 13 Dec 2017 15:31:21 +0100 |
parent | 8490:7540019afcd8 |
child | 8492:2dd07828ede1 |
comparison
equal
deleted
inserted
replaced
8490:7540019afcd8 | 8491:f134be08a499 |
---|---|
463 local session = sessions[context.sid]; | 463 local session = sessions[context.sid]; |
464 if session then | 464 if session then |
465 if not context.defer and session.bosh_deferred then | 465 if not context.defer and session.bosh_deferred then |
466 -- Handle deferred stanzas now | 466 -- Handle deferred stanzas now |
467 local deferred_stanzas = session.bosh_deferred; | 467 local deferred_stanzas = session.bosh_deferred; |
468 local context = deferred_stanzas.context; | 468 local deferred_context = deferred_stanzas.context; |
469 session.bosh_deferred = nil; | 469 session.bosh_deferred = nil; |
470 log("debug", "Handling deferred stanzas from rid %d", deferred_stanzas.rid); | 470 log("debug", "Handling deferred stanzas from rid %d", deferred_stanzas.rid); |
471 session.rid = deferred_stanzas.rid; | 471 session.rid = deferred_stanzas.rid; |
472 t_insert(session.requests, context.response); | 472 t_insert(session.requests, deferred_context.response); |
473 for _, stanza in ipairs(deferred_stanzas) do | 473 for _, stanza in ipairs(deferred_stanzas) do |
474 stream_callbacks.handlestanza(context, stanza); | 474 stream_callbacks.handlestanza(deferred_context, stanza); |
475 end | 475 end |
476 if deferred_stanzas.terminate then | 476 if deferred_stanzas.terminate then |
477 session.bosh_terminate = true; | 477 session.bosh_terminate = true; |
478 end | 478 end |
479 end | 479 end |