Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#12040 closed Bug Report - Crash (fixed)

Core dump in MythUIButtonList::GetItemCurrent

Reported by: faginbagin <mythtv@…> Owned by: stuartm
Priority: blocker Milestone: 0.27.1
Component: MythTV - General Version: 0.27-fixes
Severity: high Keywords:
Cc: Ticket locked: no

Description

I think this line (~1564) in MythUIButtonList::GetItemCurrent?():

    if (m_itemList.isEmpty() || m_selPosition > m_itemList.size() ||

should be changed to:

    if (m_itemList.isEmpty() || m_selPosition >= m_itemList.size() ||

to prevent a core dump like the one I saw. See attached stack trace, in particular thread 1 where the Qt library throws an assertion when a couple of lines later, an attempt is made to fetch the item at position 2 (the third item). Examination of m_itemList shows it has a size of 2.

Looking back at the logs, it appears mythfrontend was coming out of playback mode and there had been a decoding error. I think another frontend had deleted another recording of the same series shortly before that time. Perhaps that's a clue to reproducing the crash?

Attachments (2)

gdb.txt (102.5 KB) - added by faginbagin <mythtv@…> 6 years ago.
full stack trace
mythfrontend.log (2.7 KB) - added by faginbagin <mythtv@…> 6 years ago.
log entries from the time up to the core dump

Download all attachments as: .zip

Change History (7)

Changed 6 years ago by faginbagin <mythtv@…>

Attachment: gdb.txt added

full stack trace

Changed 6 years ago by faginbagin <mythtv@…>

Attachment: mythfrontend.log added

log entries from the time up to the core dump

comment:1 Changed 6 years ago by stuartm

Milestone: unknown0.27.1
Owner: set to stuartm
Priority: minorblocker
Severity: mediumhigh
Status: newaccepted

comment:2 Changed 6 years ago by faginbagin <mythtv@…>

FYI, it happened again, this time on a different frontend, and again, a second frontend had recently deleted an episode of the same series the first frontend was playing, but not the episode being played on the first front end. I tried to reproduce it, but couldn't. Must require split second timing. I think this scenario might reproduce it. Given two front ends, FE1 and FE2:

  • display the same series in both FE1 and FE2.
  • On FE1, start playing the last episode. Advance to 1 minute from end.
  • On FE2, start playing the first episode. Delete episode.
  • On FE1, advance to end.

comment:3 Changed 6 years ago by Stuart Morgan <smorgan@…>

Resolution: fixed
Status: acceptedclosed

In 4211abf7d62b9e15a61731bd1ae19400302c92ff/mythtv:

Fix segfault in MythUIButtonList::GetItemCurrent?(). Fixes #12040

comment:4 Changed 6 years ago by Stuart Morgan <smorgan@…>

In 4ee21a4ca0c6f85e6c6b5f55cb3bbc5b623a5e14/mythtv:

Fix segfault in MythUIButtonList::GetItemCurrent?(). Fixes #12040
(cherry picked from commit 4211abf7d62b9e15a61731bd1ae19400302c92ff)

comment:5 Changed 6 years ago by Stuart Morgan <smorgan@…>

In 6955690ffba711103bbd510de47ef6fe84f7c08c/mythtv:

Fix segfault in MythUIButtonList::GetItemCurrent?(). Fixes #12040
(cherry picked from commit 4211abf7d62b9e15a61731bd1ae19400302c92ff)

Note: See TracTickets for help on using tickets.