Opened 10 years ago

Closed 10 years ago

Last modified 9 years ago

#10073 closed Bug Report - Crash (fixed)

[Crash] mythfrontend crashes when navigating in Schedule Recordings screens

Reported by: Tony Lill <ajlill@…> Owned by: cpinkham
Priority: minor Milestone: 0.25
Component: MythTV - User Interface Library Version: 0.24.1
Severity: medium Keywords:
Cc: Ticket locked: no


Go to Manage Recordings->Schedule Recordings->Search Lists->New Titles->All and hit the END key. There's about a 50% chance that it will crash when you do. This seems to affect all the lists under Schedule Recordings when switching using the HOME or END keys or changing the sorting using 1 or 2. Basically anything that redraws a screen full of program listings.

Attachments (2)

gdb.txt (46.5 KB) - added by Tony Lill <ajlill@…> 10 years ago.
myth.log (3.8 KB) - added by Tony Lill <ajlill@…> 10 years ago.
log file

Download all attachments as: .zip

Change History (8)

Changed 10 years ago by Tony Lill <ajlill@…>

Attachment: gdb.txt added


Changed 10 years ago by Tony Lill <ajlill@…>

Attachment: myth.log added

log file

comment:1 Changed 10 years ago by paulh

This looks like a duplicate of #9388 and #9547 and is caused by two threads trying to access MythUIType member variables at the same time, usually m_DirtyRegion is involved from the crashes I've seen.

The two threads involved in this crash are the main thread running the gui and the thread fired up by MythScreenType::LoadInBackground?(). Both threads try to access MythUITypes at the same time resulting in random crashes. There's also a similar crash involving the main gui thread and the background image loading thread.

comment:2 Changed 10 years ago by stuartm

As the code for Load() says - " This method should only load data, it should never perform UI routines"

Although I accept that this wasn't added a doxygen comment so anyone relying on just the header/doxygen docs would have missed this. I'll improve the documentation but someone will have to fix proglister so that it doesn't touch UI stuff.

comment:3 Changed 10 years ago by stuartm

Just to correct myself, the header also carries the warning - " ONLY to be used for loading data, NO UI WORK"

comment:4 Changed 10 years ago by cpinkham

Owner: changed from stuartm to cpinkham
Status: newassigned

comment:5 Changed 10 years ago by Github

Milestone: unknown0.25
Resolution: fixed
Status: assignedclosed

Don't manipulate ProgList? MythUI elements outside the UI thread

FillItemList? is called both in the UI thread and outside the UI thread. Outside the UI thread, 'allowDisp' is false. We don't need to call m_progList->Reset() inside FillItemList? because it is called inside UpdateDisplay?() which is called from FillItemList? when updateDisp is true.

This commit also refactors the two UpdateDisplay?() methods a little and adds a new RestoreSelection?() method to perform the position restoration that was originally in the 2nd UpdateDisplay?() method.

Fixes #10073.

Branch: master Changeset: 8fed79e19f3fd6fada5c37f3ec3fc9224f872253

comment:6 Changed 9 years ago by Tony Lill <ajlill@…>

Backported this to 0.24 (just a bit of fuzz applying the patch) and it works great. Perhaps someone could do this in git?

Note: See TracTickets for help on using tickets.