From 9f5cc5f1761edbc70ba554d2cce3f60e5eb2cd88 Mon Sep 17 00:00:00 2001 From: "timeless%mozdev.org" Date: Sat, 10 May 2008 21:56:22 +0000 Subject: [PATCH] Bug 11054 Ignore (kill) a Subthread (branch: not the whole thread) (Troll) handle failure [@ nsNNTPNewsgroupList::ApplyFilterHit] r=Pidgeot18@gmail.com sr=neil git-svn-id: svn://10.0.0.236/trunk@251521 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/mailnews/news/src/nsNNTPNewsgroupList.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/mozilla/mailnews/news/src/nsNNTPNewsgroupList.cpp b/mozilla/mailnews/news/src/nsNNTPNewsgroupList.cpp index e09772195b3..c85fb161f0b 100644 --- a/mozilla/mailnews/news/src/nsNNTPNewsgroupList.cpp +++ b/mozilla/mailnews/news/src/nsNNTPNewsgroupList.cpp @@ -790,11 +790,13 @@ NS_IMETHODIMP nsNNTPNewsgroupList::ApplyFilterHit(nsIMsgFilter *aFilter, nsIMsgW break; case nsMsgFilterAction::KillThread: { - PRUint32 newFlags; nsCOMPtr thread; - m_newsDB->GetThreadContainingMsgHdr(m_newMsgHdr, getter_AddRefs(thread) ); - thread->GetFlags(&newFlags); - thread->SetFlags(newFlags | MSG_FLAG_IGNORED); + rv = m_newsDB->GetThreadContainingMsgHdr(m_newMsgHdr, getter_AddRefs(thread) ); + if (NS_SUCCEEDED(rv)) { + PRUint32 newFlags; + thread->GetFlags(&newFlags); + thread->SetFlags(newFlags | MSG_FLAG_IGNORED); + } } break; case nsMsgFilterAction::KillSubthread: