From 29ae06a0cd9786fd762d6fb2352d0617a7f3e6b8 Mon Sep 17 00:00:00 2001 From: "waterson%netscape.com" Date: Tue, 23 Nov 1999 22:59:02 +0000 Subject: [PATCH] Bug 19968. Just 'throw' if we can't create an RDF container on the thing. --- rdf/base/src/nsRDFContainer.cpp | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/rdf/base/src/nsRDFContainer.cpp b/rdf/base/src/nsRDFContainer.cpp index 032ff1d10d10..a81368b1684e 100644 --- a/rdf/base/src/nsRDFContainer.cpp +++ b/rdf/base/src/nsRDFContainer.cpp @@ -146,17 +146,10 @@ RDFContainerImpl::Init(nsIRDFDataSource *aDataSource, nsIRDFResource *aContainer rv = gRDFContainerUtils->IsContainer(aDataSource, aContainer, &isContainer); if (NS_FAILED(rv)) return rv; - if (! isContainer) { -#ifdef DEBUG - nsCAutoString msg; - nsXPIDLCString uri; - aContainer->GetValue(getter_Copies(uri)); - msg += uri; - msg += " is not an RDF container"; - NS_WARNING((const char*) msg); -#endif - return NS_ERROR_UNEXPECTED; - } + // ``throw'' if we can't create a container on the specified + // datasource/resource combination. + if (! isContainer) + return NS_ERROR_FAILURE; NS_IF_RELEASE(mDataSource); mDataSource = aDataSource;