Opened 11 years ago

Closed 11 years ago

#6100 closed defect (fixed)

QString segfault from PlayerContext::GetPreviousChannel

Reported by: anonymous Owned by: danielk
Priority: minor Milestone: 0.22
Component: mythtv Version: head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

Trunk rev 19625.

Reproduce with:

  1. Open LiveTV
  2. change channel once
  3. hit PreviousChannel? (first time works)
  4. hit PreviousChannel? agan ---> crash
Thread 1 (process 9100):
#0  0x08081259 in QString (this=0xbfcd61d4, other=@0x200) at /usr/include/qt4/QtCore/qstring.h:670
#1  0xb795c49b in PlayerContext::GetPreviousChannel (this=0xb2366a70) at playercontext.cpp:644
#2  0xb7874a01 in TV::ShowPreviousChannel (this=0x9e5dfc98, ctx=0xb2366a70) at tv_play.cpp:6597
#3  0xb7885cf9 in TV::PopPreviousChannel (this=0x9e5dfc98, ctx=0xb2366a70, immediate_change=false) at tv_play.cpp:6627
#4  0xb78d7f77 in TV::ActivePostQHandleAction (this=0x9e5dfc98, ctx=0xb2366a70, actions=@0xbfcd640c, isDVD=false) at tv_play.cpp:4326
#5  0xb78d9535 in TV::ProcessKeypress (this=0x9e5dfc98, actx=0xb2366a70, e=0x892f248) at tv_play.cpp:3323
#6  0xb78e5fd1 in TV::timerEvent (this=0x9e5dfc98, te=0xbfcd6acc) at tv_play.cpp:2337
#7  0xb556f53f in QObject::event () from /usr/lib/libQtCore.so.4
#8  0xb58828ec in QApplicationPrivate::notify_helper () from /usr/lib/libQtGui.so.4
#9  0xb588a72e in QApplication::notify () from /usr/lib/libQtGui.so.4
#10 0xb555fe61 in QCoreApplication::notifyInternal () from /usr/lib/libQtCore.so.4
#11 0xb558dd81 in ?? () from /usr/lib/libQtCore.so.4
#12 0xb558a520 in ?? () from /usr/lib/libQtCore.so.4
#13 0xb37c26f8 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#14 0xb37c5da3 in ?? () from /usr/lib/libglib-2.0.so.0
#15 0xb37c5f61 in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#16 0xb558a478 in QEventDispatcherGlib::processEvents () from /usr/lib/libQtCore.so.4
#17 0xb591cea5 in ?? () from /usr/lib/libQtGui.so.4
#18 0xb5560f36 in QCoreApplication::processEvents () from /usr/lib/libQtCore.so.4
#19 0xb78eaa43 in TV::StartTV (tvrec=0x0, startInGuide=false, inPlaylist=false, initByNetworkCommand=false) at tv_play.cpp:298
#20 0x0807317b in startTVNormal () at main.cpp:356
#21 0x0807e212 in TVMenuCallback (data=0x8248a60, selection=@0xb235aa08) at main.cpp:383
#22 0xb671b490 in MythThemedMenu::handleAction (this=0xb235a950, action=@0xad113d8c) at myththemedmenu.cpp:672
#23 0xb671b54d in MythThemedMenu::buttonAction (this=0xb235a950, item=0xad172780) at myththemedmenu.cpp:552
#24 0xb67a8d41 in MythThemedMenu::qt_metacall (this=0xb235a950, _c=QMetaObject::InvokeMetaMethod, _id=1, _a=0xbfcd727c) at moc_myththemedmenu.cpp:69
#25 0xb5574a60 in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#26 0xb55757e2 in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#27 0xb67aa83a in MythUIButtonList::itemClicked (this=0xb235ff10, _t1=0xad172780) at moc_mythuibuttonlist.cpp:94
#28 0xb6730857 in MythUIButtonList::keyPressEvent (this=0xb235ff10, e=0xbfcd779c) at mythuibuttonlist.cpp:873
#29 0xb671b63a in MythThemedMenu::keyPressEvent (this=0xb235a950, event=0xbfcd779c) at myththemedmenu.cpp:215
#30 0xb66af3b5 in MythMainWindow::eventFilter (this=0x830af08, e=0xbfcd779c) at mythmainwindow.cpp:1349
#31 0xb555f04a in QCoreApplicationPrivate::sendThroughObjectEventFilters () from /usr/lib/libQtCore.so.4
#32 0xb58828ca in QApplicationPrivate::notify_helper () from /usr/lib/libQtGui.so.4
#33 0xb588b806 in QApplication::notify () from /usr/lib/libQtGui.so.4
#34 0xb555fe61 in QCoreApplication::notifyInternal () from /usr/lib/libQtCore.so.4
#35 0xb58e33de in ?? () from /usr/lib/libQtGui.so.4
#36 0xb5919bb0 in ?? () from /usr/lib/libQtGui.so.4
#37 0xb591bd26 in ?? () from /usr/lib/libQtGui.so.4
#38 0xb58f2af5 in QApplication::x11ProcessEvent () from /usr/lib/libQtGui.so.4
#39 0xb591d7aa in ?? () from /usr/lib/libQtGui.so.4
#40 0xb37c26f8 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#41 0xb37c5da3 in ?? () from /usr/lib/libglib-2.0.so.0
#42 0xb37c5f61 in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#43 0xb558a478 in QEventDispatcherGlib::processEvents () from /usr/lib/libQtCore.so.4
#44 0xb591cea5 in ?? () from /usr/lib/libQtGui.so.4
#45 0xb555e52a in QEventLoop::processEvents () from /usr/lib/libQtCore.so.4
#46 0xb555e6ea in QEventLoop::exec () from /usr/lib/libQtCore.so.4
#47 0xb5560da5 in QCoreApplication::exec () from /usr/lib/libQtCore.so.4
#48 0xb5882767 in QApplication::exec () from /usr/lib/libQtGui.so.4
#49 0x0807c217 in main (argc=3, argv=0xbfcd86d4) at main.cpp:1395

Change History (2)

comment:1 Changed 11 years ago by danielk

Milestone: unknown0.22
Owner: changed from Isaac Richards to danielk
Status: newaccepted

comment:2 Changed 11 years ago by danielk

Resolution: fixed
Status: acceptedclosed

(In [19632]) Fixes #6100. Adds some bounds checking for PlayerContext::GetPreviousChannel?() && PlayerContext::PopPreviousChannel?(). One missing check was due to a typo, the other was just missing.

Note: See TracTickets for help on using tickets.