summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonatan Lindblad <jlindblad@mythtv.org>2012-04-15 10:57:58 (GMT)
committer Jonatan Lindblad <jlindblad@mythtv.org>2012-04-15 10:57:58 (GMT)
commit4637842926a3897445fa1dc6003260125a83a305 (patch)
tree63f7ddd11930f39a0aaf1ca75e21d39a2159ffe1
parent4b7e39e5891f0eee4728bba7f4a12bcc72e3e5c2 (diff)
MythNetvision: Fix segmentation fault in NetTree::showMenu
Fixes #10603 Also removed some unused code. (cherry picked from commit ba9bcba84c386adc68815c5301f32990872e8e1f) Conflicts: mythplugins/mythnetvision/mythnetvision/nettree.cpp mythplugins/mythnetvision/mythnetvision/rsseditor.cpp
-rw-r--r--mythplugins/mythnetvision/mythnetvision/nettree.cpp7
-rw-r--r--mythplugins/mythnetvision/mythnetvision/rsseditor.cpp6
2 files changed, 6 insertions, 7 deletions
diff --git a/mythplugins/mythnetvision/mythnetvision/nettree.cpp b/mythplugins/mythnetvision/mythnetvision/nettree.cpp
index 9601aac..862a398 100644
--- a/mythplugins/mythnetvision/mythnetvision/nettree.cpp
+++ b/mythplugins/mythnetvision/mythnetvision/nettree.cpp
@@ -495,7 +495,12 @@ void NetTree::showMenu(void)
ResultItem *item = NULL;
if (m_type == DLG_TREE)
- item = qVariantValue<ResultItem *>(m_siteMap->GetCurrentNode()->GetData());
+ {
+ MythGenericTree *node = m_siteMap->GetCurrentNode();
+
+ if (node)
+ item = qVariantValue<ResultItem *>(node->GetData());
+ }
else
{
MythGenericTree *node = GetNodePtrFromButton(m_siteButtonList->GetItemCurrent());
diff --git a/mythplugins/mythnetvision/mythnetvision/rsseditor.cpp b/mythplugins/mythnetvision/mythnetvision/rsseditor.cpp
index 2cf9873..a9672e7 100644
--- a/mythplugins/mythnetvision/mythnetvision/rsseditor.cpp
+++ b/mythplugins/mythnetvision/mythnetvision/rsseditor.cpp
@@ -222,12 +222,6 @@ void RSSEditPopup::slotSave(QNetworkReply* reply)
QString author = m_authorEdit->GetText();
QString file = m_thumbImage->GetFilename();
- bool download;
- if (m_download->GetCheckState() == MythUIStateType::Full)
- download = true;
- else
- download = false;
-
VERBOSE(VB_GENERAL|VB_EXTRA, QString("Text to Parse: %1").arg(text));
QDomElement root = document.documentElement();