# HG changeset patch # User Kim Alvefur # Date 1347465835 -7200 # Node ID 0095b74a3685830c2d2691d494319845da70d701 # Parent e2d940d81613e715bb4ac8224bf4a2f91a3f63bb mod_smacks: Avoid indexing a nil value diff -r e2d940d81613 -r 0095b74a3685 mod_smacks/mod_smacks.lua --- a/mod_smacks/mod_smacks.lua Mon Sep 10 21:11:04 2012 +0200 +++ b/mod_smacks/mod_smacks.lua Wed Sep 12 18:03:55 2012 +0200 @@ -225,7 +225,7 @@ -- (for example, the client may have bound a new resource and -- started a new smacks session, or not be using smacks) local curr_session = full_sessions[session.full_jid]; - if curr_session.resumption_token == resumption_token + if curr_session and curr_session.resumption_token == resumption_token -- Check the hibernate time still matches what we think it is, -- otherwise the session resumed and re-hibernated. and session.hibernating == hibernate_time then