[mythtv-commits] Ticket #7066: LiveTV hangs occasionaly when changing channels
MythTV
mythtv at cvs.mythtv.org
Tue Sep 15 17:43:01 UTC 2009
#7066: LiveTV hangs occasionaly when changing channels
--------------------------+-------------------------------------------------
Reporter: anonymous | Owner: janne
Type: defect | Status: new
Priority: critical | Milestone: 0.22
Component: MythTV - DVB | Version: head
Severity: high | Mlocked: 0
--------------------------+-------------------------------------------------
Sometimes when changing channels livetv will hang with no other recourse
that to kill the frontend and restart.
The frontend shows:
{{{
2009-09-15 21:22:41.040 LiveTVChain(live-htpc-2009-09-15T21:22:40):
ReloadAll(): Added new recording
2009-09-15 21:22:41.077 We have a
playbackURL(myth://1.0.0.10:6543/3434_20090915212240.mpg) &
cardtype(DUMMY)
2009-09-15 21:22:41.077 We have a RingBuffer
2009-09-15 21:22:41.078 TV Error: LiveTV not successfully started
2009-09-15 21:22:41.078 TV: HandleStateChange(0) -- end
2009-09-15 21:22:41.078 TV: TeardownPlayer() player ctx 0
2009-09-15 21:22:45.567 TV: StartTV -- process events end
2009-09-15 21:22:45.568 TV: tv->LiveTV() -- begin
2009-09-15 21:22:45.572 TV: tv->LiveTV() -- end
2009-09-15 21:22:45.572 TV: StartTV -- process events begin
}}}
I attached a debugger to the FE process and it shows we are stuck on a
condvar
{{{
(gdb) where
#0 0xffffe424 in __kernel_vsyscall ()
#1 0xb4e70bbb in pthread_cond_timedwait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#2 0xb4fb7dc4 in QWaitCondition::wait () from /usr/lib/libQtCore.so.4
#3 0xb7800635 in TV::StartTV (tvrec=0x0, startInGuide=false,
inPlaylist=false, initByNetworkCommand=false) at tv_play.cpp:331
#4 0x08077632 in startTVNormal () at main.cpp:414
#5 0x08082a9e in TVMenuCallback (data=0x82f70f0, selection=@0xb055a82c)
at main.cpp:441
#6 0xb640705a in MythThemedMenu::handleAction (this=0xb055a768,
action=@0x85eebc4, password=@0xbf84ab00) at myththemedmenu.cpp:847
#7 0xb6407420 in MythThemedMenu::buttonAction (this=0xb055a768,
item=0x85ede70, skipPass=false) at myththemedmenu.cpp:716
#8 0xb649ff93 in MythThemedMenu::qt_metacall (this=0xb055a768,
_c=QMetaObject::InvokeMetaMethod, _id=2, _a=0xbf84ac10)
at moc_myththemedmenu.cpp:73
#9 0xb50be967 in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#10 0xb50bf082 in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#11 0xb64a1fb9 in MythUIButtonList::itemClicked (this=0xb057df30,
_t1=0x85ede70) at moc_mythuibuttonlist.cpp:96
#12 0xb6425b30 in MythUIButtonList::keyPressEvent (this=0xb057df30,
e=0xbf84b188) at mythuibuttonlist.cpp:867
#13 0xb6407f40 in MythThemedMenu::keyPressEvent (this=0xb055a768,
event=0xbf84b188) at myththemedmenu.cpp:211
#14 0xb638b9c2 in MythMainWindow::eventFilter (this=0x835c6a8,
e=0xbf84b188) at mythmainwindow.cpp:1399
#15 0xb50a95c1 in QCoreApplicationPrivate::sendThroughObjectEventFilters
() from /usr/lib/libQtCore.so.4
#16 0xb56290c3 in QApplicationPrivate::notify_helper () from
/usr/lib/libQtGui.so.4
#17 0xb562df8a in QApplication::notify () from /usr/lib/libQtGui.so.4
#18 0xb50a922b in QCoreApplication::notifyInternal () from
/usr/lib/libQtCore.so.4
#19 0xb6616b08 in QCoreApplication::sendEvent (receiver=0x835c6a8,
event=0xbf84b188) at /usr/include/QtCore/qcoreapplication.h:213
#20 0xb6391e2b in MythMainWindow::customEvent (this=0x835c6a8,
ce=0x84a5bc8) at mythmainwindow.cpp:1578
#21 0xb50ba35f in QObject::event () from /usr/lib/libQtCore.so.4
#22 0xb5683445 in QWidget::event () from /usr/lib/libQtGui.so.4
#23 0xb6392fd4 in MythMainWindow::event (this=0x835c6a8, e=0x84a5bc8) at
mythmainwindow.cpp:714
#24 0xb56290ec in QApplicationPrivate::notify_helper () from
/usr/lib/libQtGui.so.4
#25 0xb562dc17 in QApplication::notify () from /usr/lib/libQtGui.so.4
#26 0xb50a922b in QCoreApplication::notifyInternal () from
/usr/lib/libQtCore.so.4
#27 0xb50aa539 in QCoreApplicationPrivate::sendPostedEvents () from
/usr/lib/libQtCore.so.4
#28 0xb50aa75d in QCoreApplication::sendPostedEvents () from
/usr/lib/libQtCore.so.4
#29 0xb50d50cf in ?? () from /usr/lib/libQtCore.so.4
#30 0xb4eb00f9 in IA__g_main_context_dispatch (context=0x82d0220) at
gmain.c:1960
#31 0xb4eb2ee6 in g_main_context_iterate (context=0x82d0220, block=1,
dispatch=1, self=0x82ce040) at gmain.c:2591
#32 0xb4eb335c in IA__g_main_context_iteration (context=0x82d0220,
may_block=1) at gmain.c:2654
#33 0xb50d54a8 in QEventDispatcherGlib::processEvents () from
/usr/lib/libQtCore.so.4
#34 0xb56c2845 in ?? () from /usr/lib/libQtGui.so.4
#35 0xb50a843d in QEventLoop::processEvents () from
/usr/lib/libQtCore.so.4
---Type <return> to continue, or q <return> to quit---
#36 0xb50a86ba in QEventLoop::exec () from /usr/lib/libQtCore.so.4
#37 0xb50aa821 in QCoreApplication::exec () from /usr/lib/libQtCore.so.4
#38 0xb5628a37 in QApplication::exec () from /usr/lib/libQtGui.so.4
#39 0x0808068c in main (argc=5, argv=0xbf84c034) at main.cpp:1515
(gdb)
}}}
This (on svn) corresponds to
{{{
312 VERBOSE(VB_PLAYBACK, LOC + "StartTV -- process events
begin");
313 MythTimer st; st.start();
314 bool is_started = false;
315 while (true)
316 {
317 qApp->processEvents();
318
319 QMutexLocker locker(&tv->stateChangeCondLock);
320 TVState state = tv->GetState(0);
321 bool is_err = kState_Error == state;
322 bool is_none = kState_None == state;
323 is_started = is_started ||
324 (st.elapsed() > (int)
TV::kEndOfPlaybackFirstCheckTimer) ||
325 (!is_none && !is_err && kState_ChangingState !=
state);
326 if (is_err || (is_none && is_started))
327 break;
328
329 // timeout needs to be low enough to process keyboard
input
330 unsigned long timeout = 20; // milliseconds
>>>331 tv->stateChangeCond.wait(&tv->stateChangeCondLock,
timeout);
332 }
333 VERBOSE(VB_PLAYBACK, LOC + "StartTV -- process events
end");
334
}}}
We never come out of this wait...
--
Ticket URL: <http://svn.mythtv.org/trac/ticket/7066>
MythTV <http://www.mythtv.org/>
MythTV
More information about the mythtv-commits
mailing list