#1777 mod_admin_shell.lua:748: attempt to index a nil value (local 'conn')
Reporter
Stefan Haan
Owner
Zash
Created
Updated
Stars
★ (1)
Tags
Difficulty-Easy
Milestone-0.12
Priority-Medium
Status-Fixed
Type-Defect
Stefan Haan
on
What steps will reproduce the problem?
1. Have users using Monal on the server
2. ???
3. prosody> c2s:show(nil, "jid port")
What is the expected output?
```
| JID | Port
| user1@domain.tld/gajim.CATBOA… | 5223
| user1@domain.tld/Conversation… | 5223
| user2@domain.tld/Conversation… | 5223
| user3@domain.tld/Monal-iOS.ce94… | 5223
| user3@domain.tld/Conversations.… | 5223
| user4@domain.tld/Monal-iOS.4… | 5223
| OK: 6 c2s sessions shown
```
What do you see instead?
```
| JID | Port
| user1@domain.tld/gajim.CATBOA… | 5223
| user1@domain.tld/Conversation… | 5223
| user2@domain.tld/Conversation… | 5223
! /usr/lib/prosody/modules/mod_admin_shell.lua:748: attempt to index a nil value (local 'conn')
```
What version of the product are you using? On what operating system?
Prosody 0.12.1 on Linux 5.19.10-arch1-1
Zash
on
Thanks for the report.
This likely happens to disconnected sessions in the mod_smacks "hibernating" state, where they don't have a 'conn' (-ection) property.
Probably an easy fix to check for that.
`c2s:show(nil, "jid smacks")` could confirm the hibernating state.
What steps will reproduce the problem? 1. Have users using Monal on the server 2. ??? 3. prosody> c2s:show(nil, "jid port") What is the expected output? ``` | JID | Port | user1@domain.tld/gajim.CATBOA… | 5223 | user1@domain.tld/Conversation… | 5223 | user2@domain.tld/Conversation… | 5223 | user3@domain.tld/Monal-iOS.ce94… | 5223 | user3@domain.tld/Conversations.… | 5223 | user4@domain.tld/Monal-iOS.4… | 5223 | OK: 6 c2s sessions shown ``` What do you see instead? ``` | JID | Port | user1@domain.tld/gajim.CATBOA… | 5223 | user1@domain.tld/Conversation… | 5223 | user2@domain.tld/Conversation… | 5223 ! /usr/lib/prosody/modules/mod_admin_shell.lua:748: attempt to index a nil value (local 'conn') ``` What version of the product are you using? On what operating system? Prosody 0.12.1 on Linux 5.19.10-arch1-1
Thanks for the report. This likely happens to disconnected sessions in the mod_smacks "hibernating" state, where they don't have a 'conn' (-ection) property. Probably an easy fix to check for that. `c2s:show(nil, "jid smacks")` could confirm the hibernating state.
ChangesFixed in https://hg.prosody.im/trunk/rev/3735ad8d6f8e
Changes