Windows XBMC crashes when XBOX-controller disconnects

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
tjcinnamon Offline
Senior Member
Posts: 211
Joined: Apr 2012
Reputation: 0
Post: #41
What is the error? What type of file? Are you using a remote? If so, what remote are you using?

Frodo Win 8 Pro x64
Fractal Design Node 605 (looks amazing)
i5 3570K, Asus P8Z77V LK
2x80GB Intel 320 SSD, 4TB NAS
GTX 670x2 SLI, 16GB GSkill Ares
Onkyo RC360 with Paradigm piece-by-piece 5.1 build
Nyxboard and AHK full controlled via XBox Controller
find quote
WiSo Offline
Team-XBMC Developer
Posts: 2,481
Joined: Oct 2003
Reputation: 0
Location: Germany
Post: #42
(2012-04-26 14:42)evil-B Wrote:  I guess it is not a fix but a workaround. This 'g_Joystick.Reinitialize()' is here to detect new joysticks which were not there when XBMC started... but obviously it doesn't work yet. The reinitialization of the SDL layer crashes, I don't know why and I don't have time nor the will to investigate it deeper.
Official coders, it is up to you now Wink

Nope. CrystalP doesn't have a xbox360 controller and it didn't crash for me anymore with my wired xbox360 controller. If anyone is able to fix it than someone who can reproduce it. That it crashes inside SDL just means that somehow SDL doesn't get the state of the controller somehow. It might be enough that g_Joystick.Reinitialize() just needs to be called somewhere else.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
find quote
tjcinnamon Offline
Senior Member
Posts: 211
Joined: Apr 2012
Reputation: 0
Post: #43
I can confirm that the patched version where g_Joystick.Reinitialize() is commented out cannot play videos.

Here is the debug log from when the patched version could not play videos:

http://pastebin.com/PXS2N4bA

Frodo Win 8 Pro x64
Fractal Design Node 605 (looks amazing)
i5 3570K, Asus P8Z77V LK
2x80GB Intel 320 SSD, 4TB NAS
GTX 670x2 SLI, 16GB GSkill Ares
Onkyo RC360 with Paradigm piece-by-piece 5.1 build
Nyxboard and AHK full controlled via XBox Controller
find quote
evil-B Offline
Junior Member
Posts: 28
Joined: Feb 2011
Reputation: 0
Post: #44
ah the usual 'do it yourself' answer from the XBMC dev... I understand your position, I am a long time C++ coder myself but I also understand that this is a very frustrating answer for the standard user. But this is another subject...

OK so I did some debugging against my will Smile

What I found is that, for some unknown reason, sometimes (not all the time on my dev computer) the call to SDL_InitSubSystem() in CJoystick::Reinitialize() throws an exception. This exception is caught by the exception bail out system in XBApplicationEx.cpp. However from this point the g_Joystick object is in an unknown state and in my case crashes in a subsequent call to CJoystick::Update().

I added a m_boInit variable which is set to false until the object is correctly initialized. It is set to true at the end of Initialize() and Reinitialize().
Then all public functions (or functions making calls to SDL_ functions) quickly return if m_boInit is false. From there I was unable to crash XBMC again. I will do some more tests on my HTPC later to make sure it was not just luck.
find quote
tjcinnamon Offline
Senior Member
Posts: 211
Joined: Apr 2012
Reputation: 0
Post: #45
Excellent work!

Thanks for taking time to do this!

Frodo Win 8 Pro x64
Fractal Design Node 605 (looks amazing)
i5 3570K, Asus P8Z77V LK
2x80GB Intel 320 SSD, 4TB NAS
GTX 670x2 SLI, 16GB GSkill Ares
Onkyo RC360 with Paradigm piece-by-piece 5.1 build
Nyxboard and AHK full controlled via XBox Controller
find quote
evil-B Offline
Junior Member
Posts: 28
Joined: Feb 2011
Reputation: 0
Post: #46
I don't have the problem with playing videos myself (tested over SMB from my dev PC). I don't see why the SDL layer would impact the video player but if it does it can be interesting to investigate.

Take my comments for what they are: I am a long time C++ coder but I have very limited understanding of the XBMC overall architecture. An experienced XBMC dev should be an asset here.
Here is my untested latest build:
http://ryushare.com/ca0nkno3ypc1/XBMC.zip
Be aware that this is for XBMC adventurers only !
(This post was last modified: 2012-04-26 21:12 by evil-B.)
find quote
WiSo Offline
Team-XBMC Developer
Posts: 2,481
Joined: Oct 2003
Reputation: 0
Location: Germany
Post: #47
(2012-04-26 20:53)evil-B Wrote:  ah the usual 'do it yourself' answer from the XBMC dev... I understand your position, I am a long time C++ coder myself but I also understand that this is a very frustrating answer for the standard user. But this is another subject...

I'm no developer in my day to day job so you might be even more skilled to find and fix the problem Wink I just could say nothing but I try to give some pointers where others can chime in. budget planning and other things keeping me busy in RL so I'm not really in a mood for fixing bugs I can't replicate with the debugger.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
(This post was last modified: 2012-04-26 21:40 by WiSo.)
find quote
achaw Offline
Junior Member
Posts: 41
Joined: Mar 2012
Reputation: 0
Post: #48
Can´t see movie either with this workaround:

Code:
17:33:28 T:3524   DEBUG: CUtil::ScanForExternalSubtitles: END (total time: 3 ms)
17:33:28 T:3524  NOTICE: Creating Demuxer
17:33:28 T:3524   DEBUG: SECTION:LoadDLL(special://xbmcbin/system/players/dvdplayer/avutil-51.dll)
17:33:28 T:3524   ERROR: Win32DllLoader::Load: Failed to load C:\Program Files (x86)\XBMC\system\players\dvdplayer\avutil-51.dll with error 126:No se puede encontrar el m�dulo especificado.
17:33:28 T:3524   ERROR: CDVDDemuxFFmpeg::Open - failed to load ffmpeg libraries
17:33:28 T:3524   ERROR: CDVDPlayer::OpenDemuxStream - Error creating demuxer
17:33:28 T:3524  NOTICE: CDVDPlayer::OnExit()
17:33:28 T:3524  NOTICE: CDVDPlayer::OnExit() deleting input stream
17:33:28 T:3524   DEBUG: Thread CDVDPlayer 3524 terminating
17:33:28 T:3052   DEBUG: CAnnouncementManager - Announcement: OnStop from xbmc
17:33:28 T:3052   DEBUG: GOT ANNOUNCEMENT, type: 1, from xbmc, message OnStop
17:33:28 T:3052   ERROR: Playlist Player: skipping unplayable item: 0, path [C:\Users\HT\MEDIA\Peliculas\The Tree Of Life.avi]
17:33:28 T:3052   DEBUG: Playlist Player: no more playable items... aborting playback
17:33:28 T:1364   DEBUG: Thread Background Loader start, auto delete: 0
17:33:28 T:3052  NOTICE: CDVDPlayer::CloseFile()
17:33:28 T:3052 WARNING: CDVDMessageQueue(player)::Put MSGQ_NOT_INITIALIZED
17:33:28 T:3052  NOTICE: DVDPlayer: waiting for threads to exit
17:33:28 T:3052  NOTICE: DVDPlayer: finished waiting
17:33:28 T:1364   DEBUG: Thread Background Loader 1364 terminating
17:33:35 T:3052   DEBUG: ------ Window Init (Pointer.xml) ------
17:33:41 T:3052   DEBUG: ------ Window Deinit (Pointer.xml) ------
17:33:46 T:3052   ERROR: XFILE::CDirectory::GetDirectory - Error getting C:\Users\HT\MEDIA\Peliculas\/extrafanart\
17:33:57 T:2692   DEBUG: Thread Jobworker 2692 terminating (autodelete)
17:33:57 T:328   DEBUG: Thread Jobworker 328 terminating (autodelete)
17:33:57 T:1136   DEBUG: Thread Jobworker 1136 terminating (autodelete)
17:33:57 T:3052   DEBUG: SECTION:UnloadDelayed(DLL: special://xbmcbin/system/ImageLib.dll)
find quote
tjcinnamon Offline
Senior Member
Posts: 211
Joined: Apr 2012
Reputation: 0
Post: #49
(2012-04-26 22:50)achaw Wrote:  Can´t see movie either with this workaround:

Code:
17:33:28 T:3524   DEBUG: CUtil::ScanForExternalSubtitles: END (total time: 3 ms)
17:33:28 T:3524  NOTICE: Creating Demuxer
17:33:28 T:3524   DEBUG: SECTION:LoadDLL(special://xbmcbin/system/players/dvdplayer/avutil-51.dll)
17:33:28 T:3524   ERROR: Win32DllLoader::Load: Failed to load C:\Program Files (x86)\XBMC\system\players\dvdplayer\avutil-51.dll with error 126:No se puede encontrar el m�dulo especificado.
17:33:28 T:3524   ERROR: CDVDDemuxFFmpeg::Open - failed to load ffmpeg libraries
17:33:28 T:3524   ERROR: CDVDPlayer::OpenDemuxStream - Error creating demuxer
17:33:28 T:3524  NOTICE: CDVDPlayer::OnExit()
17:33:28 T:3524  NOTICE: CDVDPlayer::OnExit() deleting input stream
17:33:28 T:3524   DEBUG: Thread CDVDPlayer 3524 terminating
17:33:28 T:3052   DEBUG: CAnnouncementManager - Announcement: OnStop from xbmc
17:33:28 T:3052   DEBUG: GOT ANNOUNCEMENT, type: 1, from xbmc, message OnStop
17:33:28 T:3052   ERROR: Playlist Player: skipping unplayable item: 0, path [C:\Users\HT\MEDIA\Peliculas\The Tree Of Life.avi]
17:33:28 T:3052   DEBUG: Playlist Player: no more playable items... aborting playback
17:33:28 T:1364   DEBUG: Thread Background Loader start, auto delete: 0
17:33:28 T:3052  NOTICE: CDVDPlayer::CloseFile()
17:33:28 T:3052 WARNING: CDVDMessageQueue(player)::Put MSGQ_NOT_INITIALIZED
17:33:28 T:3052  NOTICE: DVDPlayer: waiting for threads to exit
17:33:28 T:3052  NOTICE: DVDPlayer: finished waiting
17:33:28 T:1364   DEBUG: Thread Background Loader 1364 terminating
17:33:35 T:3052   DEBUG: ------ Window Init (Pointer.xml) ------
17:33:41 T:3052   DEBUG: ------ Window Deinit (Pointer.xml) ------
17:33:46 T:3052   ERROR: XFILE::CDirectory::GetDirectory - Error getting C:\Users\HT\MEDIA\Peliculas\/extrafanart\
17:33:57 T:2692   DEBUG: Thread Jobworker 2692 terminating (autodelete)
17:33:57 T:328   DEBUG: Thread Jobworker 328 terminating (autodelete)
17:33:57 T:1136   DEBUG: Thread Jobworker 1136 terminating (autodelete)
17:33:57 T:3052   DEBUG: SECTION:UnloadDelayed(DLL: special://xbmcbin/system/ImageLib.dll)

Are you referring to the most recently posted patch?

Frodo Win 8 Pro x64
Fractal Design Node 605 (looks amazing)
i5 3570K, Asus P8Z77V LK
2x80GB Intel 320 SSD, 4TB NAS
GTX 670x2 SLI, 16GB GSkill Ares
Onkyo RC360 with Paradigm piece-by-piece 5.1 build
Nyxboard and AHK full controlled via XBox Controller
find quote
evil-B Offline
Junior Member
Posts: 28
Joined: Feb 2011
Reputation: 0
Post: #50
these builds are made from the latest repository version. you seem to be missing at least one dll.
find quote
Post Reply