[Pidgin] #7153: XMPP accounts stay online for hours after Hibernation

Pidgin trac at pidgin.im
Mon Apr 8 16:38:29 EDT 2013


#7153: XMPP accounts stay online for hours after Hibernation
----------------------------------------+---------------------
 Reporter:  Menedas                     |       Owner:  deryni
     Type:  defect                      |      Status:  new
Milestone:                              |   Component:  XMPP
  Version:  2.5.0                       |  Resolution:
 Keywords:  hibernation stay available  |
----------------------------------------+---------------------

Comment (by phannent):

 To me the obvious thing with this is that Pidgin doesn't get the chance to
 tell the servers its going offline. Searching around I found that there is
 a bit of a lack of an API for this, however a simple trick would be to
 shutdown Pidgin in the event of a suspend and restart it again on resume:

 [http://stackoverflow.com/q/14376534/24459
 http://stackoverflow.com/questions/14376534/how-to-detect-whether-system-
 is-going-to-standby-in-linux-using-c]

 Which informs us that if we put a file in /etc/pm/sleep.d it will execute
 it before suspend. Something like:


 {{{
 #!/bin/bash
 case $1 in
 suspend)
     #suspending to RAM
     killall -s SIGTERM pidgin
     ;;
 resume)
     #resume from suspend
     sleep 3
     pidgin
     ;;
 esac
 }}}

 Now you can just either open Pidgin or tell it to close and this bug is
 fixed outside of Pidgin.

-- 
Ticket URL: <https://developer.pidgin.im/ticket/7153#comment:3>
Pidgin <http://pidgin.im>
Pidgin


More information about the Tracker mailing list