From 5949a4607aab08c17af761dd3a7512af0f772b71 Mon Sep 17 00:00:00 2001 From: "alecf%netscape.com" Date: Sun, 18 Jun 2000 05:43:32 +0000 Subject: [PATCH] quiet down RDF by handling datasources without windows gracefully (needed for search, so I could reuse the threadpane without causing assertions) r=sspitzer for #33101 --- mailnews/base/src/nsMsgMessageDataSource.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/mailnews/base/src/nsMsgMessageDataSource.cpp b/mailnews/base/src/nsMsgMessageDataSource.cpp index fa4e6de31a7..6ce8b9cc67c 100644 --- a/mailnews/base/src/nsMsgMessageDataSource.cpp +++ b/mailnews/base/src/nsMsgMessageDataSource.cpp @@ -496,9 +496,9 @@ NS_IMETHODIMP nsMsgMessageDataSource::ArcLabelsOut(nsIRDFResource* source, PRBool showThreads; rv = GetIsThreaded(&showThreads); - if(NS_FAILED(rv)) return rv; - - if(showThreads) + // handle this failure gracefully - not all datasources have views. + + if(NS_SUCCEEDED(rv) && showThreads) { arcsArray = kThreadsArcsOutArray; } @@ -513,7 +513,7 @@ NS_IMETHODIMP nsMsgMessageDataSource::ArcLabelsOut(nsIRDFResource* source, } rv = NS_NewArrayEnumerator(labels, arcsArray); - if(NS_FAILED(rv)) return rv; + NS_ENSURE_SUCCESS(rv, rv); return NS_OK; }