2010-03-24, 21:37
Is there a way from within a script to detect that XBMC is closing, and have it run some cleanup? Catching a signal would be the best way to go.
I have a script that listens on a socket. If I us a blocking read, the script hangs when there is no data on the socket, and prevents XBMC from closing.
I've change to timeout after 2 seconds of no data, so the script doesn't really hang anymore, but that's not a real graceful fix. Also, I see a "script error" logged when XBMC exits.
Thanks!
Brian
I have a script that listens on a socket. If I us a blocking read, the script hangs when there is no data on the socket, and prevents XBMC from closing.
I've change to timeout after 2 seconds of no data, so the script doesn't really hang anymore, but that's not a real graceful fix. Also, I see a "script error" logged when XBMC exits.
Thanks!
Brian