Adding comments, per bzbarsky. bug 214050.

git-svn-id: svn://10.0.0.236/trunk@145342 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
caillon%returnzero.com
2003-07-29 19:03:00 +00:00
parent 7e62e141b3
commit 7fe85266fd

View File

@@ -778,6 +778,9 @@ nsScriptSecurityManager::CheckPropertyAccessImpl(PRUint32 aAction,
};
nsXPIDLString errorMsg;
// We need to keep our existing failure rv and not override it
// with a likely success code from the following string bundle
// call in order to throw the correct security exception later.
nsresult rv2 = sStrBundle->FormatStringFromName(stringName.get(),
formatStrings,
NS_ARRAY_LENGTH(formatStrings),
@@ -2313,6 +2316,9 @@ nsScriptSecurityManager::CanCreateWrapper(JSContext *cx,
NS_ConvertUTF8toUTF16 className(objClassInfo.GetName());
const PRUnichar* formatStrings[] = { className.get() };
nsXPIDLString errorMsg;
// We need to keep our existing failure rv and not override it
// with a likely success code from the following string bundle
// call in order to throw the correct security exception later.
nsresult rv2 =
sStrBundle->FormatStringFromName(strName.get(),
formatStrings,