Skip to content

Commit

Permalink
fixed: crash on picture load due to invalid WaitForSingleObject chang…
Browse files Browse the repository at this point in the history
…e in 8c7bdfa
  • Loading branch information
mkortstiege committed Jun 29, 2011
1 parent f0dd68e commit acdc0dd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xbmc/pictures/GUIWindowSlideShow.cpp
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ void CBackgroundPicLoader::Process()
unsigned int count = 0; unsigned int count = 0;
while (!m_bStop) while (!m_bStop)
{ // loop around forever, waiting for the app to call LoadPic { // loop around forever, waiting for the app to call LoadPic
if (AbortableWait(m_loadPic,10) == WAIT_SIGNALED) if (m_loadPic.WaitMSec(10))
{ {
if (m_pCallback) if (m_pCallback)
{ {
Expand Down

5 comments on commit acdc0dd

@elupus
Copy link
Contributor

@elupus elupus commented on acdc0dd Jun 29, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How was the old code invalid? Looks right to me.

@mkortstiege
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change made us crash.

@jmarshallnz
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure why that would make it crash - old code looks right to me as well.

@amet
Copy link
Contributor

@amet amet commented on acdc0dd Jun 29, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

crashes on OSX as well with (AbortableWait(m_loadPic,10) == WAIT_SIGNALED)

@jimfcarroll
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was a problem with the CEventGroup which wasn't resetting the child signaled state when the wait was taking place through the group. The fix is checked in as well as undoing this change. c649019

Please sign in to comment.