From 18fed7a265bbab520599d581501dce8687b47fc4 Mon Sep 17 00:00:00 2001 From: "doronr%us.ibm.com" Date: Wed, 20 Jul 2005 14:48:43 +0000 Subject: [PATCH] Bug 300130 - Schema Loader can crash if an non-existing type is referenced in a schema file. r/sr=peterv, a=mkaply --- extensions/webservices/schema/src/nsSchemaComplexType.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/webservices/schema/src/nsSchemaComplexType.cpp b/extensions/webservices/schema/src/nsSchemaComplexType.cpp index 12fe54e86b3..ee398397bd5 100644 --- a/extensions/webservices/schema/src/nsSchemaComplexType.cpp +++ b/extensions/webservices/schema/src/nsSchemaComplexType.cpp @@ -80,7 +80,7 @@ nsSchemaComplexType::Resolve(nsIWebServiceErrorHandler* aErrorHandler) nsAutoString attrName; nsresult rv1 = mAttributes.ObjectAt(i)->GetName(attrName); NS_ENSURE_SUCCESS(rv1, rv1); - + nsAutoString errorMsg; errorMsg.AppendLiteral("Failure resolving schema complex type, "); errorMsg.AppendLiteral("cannot resolve attribute \""); @@ -141,7 +141,7 @@ nsSchemaComplexType::Resolve(nsIWebServiceErrorHandler* aErrorHandler) rv = mModelGroup->Resolve(aErrorHandler); if (NS_FAILED(rv)) { nsAutoString modelName; - nsresult rv1 = type->GetName(modelName); + nsresult rv1 = mModelGroup->GetName(modelName); NS_ENSURE_SUCCESS(rv1, rv1); nsAutoString errorMsg;