Kodi crashes constantly ("Quit Unexpectedly")
#16
@"glenguy" I was looking at the source code, for fun.. It looks to me like there's plenty of potental for thread timing issues. In cdm_adapter.cc, what calls CdmAdapter::SetTimer? If SetTimer and CloseSession are called around the same time, it could easily end up calling cdm11_->TimerExpired after cdm11->CloseSession.
Reply
#17
Thanks for having a look over it. A far as I know and can see SetTimer is called by the CDM itself. But only after we call TimerExpired on the CDM i.e - if you don't do anything on SetTimer being called, then it will only ever be called the one time.
timerfunc is supposed to check the flag that's set when we want to close the session - if the flag is true then don't call TimerExpired so CDM will not try to call back, therefore theoretically avoiding a situation leading to crash. But please correct me if you think otherwise.
I'm no expert in thread safety so if you have any more insight I'd be grateful.
Reply
#18
Out of interest, in the 2nd test build you gave me what did you disable exactly?

What toolchain do you use to build this for Mac? Xcode? Any particular version? The page here doesn't mention Mac: https://github.com/xbmc/inputstream.adap...w-to-build.
Reply
#19
Changes for that last build are in here: https://github.com/xbmc/inputstream.adap...2b78f285b3

And some build info for macOS here: https://github.com/xbmc/xbmc/blob/Matrix...E.macOS.md .

Looks like an older version of xcode, not sure which newer versions will still work - haven't had time yet to look into myself.
Reply

Logout Mark Read Team Forum Stats Members Help
Kodi crashes constantly ("Quit Unexpectedly")0