Bug 1042436 - Lowercase the "reason" param to SilentFailure. a=sledru
authorBobby Holley <bobbyholley@gmail.com>
Wed, 06 Aug 2014 23:32:22 -0400
changeset 217440 704ef45176bd7f9407861b78df715c4d7804c9e8
parent 217439 2449111f679e4ebf776bccb85fdfe58e7105736d
child 217441 98d705a709c78a4ca6dd3a80d1ca1cfc2de95376
push id515
push userraliiev@mozilla.com
push dateMon, 06 Oct 2014 12:51:51 +0000
treeherdermozilla-release@267c7a481bef [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssledru
bugs1042436
milestone33.0a2
Bug 1042436 - Lowercase the "reason" param to SilentFailure. a=sledru
js/xpconnect/wrappers/XrayWrapper.cpp
--- a/js/xpconnect/wrappers/XrayWrapper.cpp
+++ b/js/xpconnect/wrappers/XrayWrapper.cpp
@@ -498,17 +498,17 @@ public:
     virtual bool resolveOwnProperty(JSContext *cx, const Wrapper &jsWrapper, HandleObject wrapper,
                                     HandleObject holder, HandleId id,
                                     MutableHandle<JSPropertyDescriptor> desc) MOZ_OVERRIDE
     {
         bool ok = XrayTraits::resolveOwnProperty(cx, jsWrapper, wrapper, holder, id, desc);
         if (!ok || desc.object())
             return ok;
 
-        return SilentFailure(cx, id, "Object is not safely Xrayable");
+        return SilentFailure(cx, id, "object is not safely Xrayable");
     }
 
     bool defineProperty(JSContext *cx, HandleObject wrapper, HandleId id,
                         MutableHandle<JSPropertyDescriptor> desc,
                         Handle<JSPropertyDescriptor> existingDesc, bool *defined)
     {
         *defined = false;
         return true;
@@ -609,56 +609,56 @@ bool JSXrayTraits::getOwnPropertyFromTar
 
     // If the property doesn't exist at all, we're done.
     if (!desc.object())
         return true;
 
     // Disallow accessor properties.
     if (desc.hasGetterOrSetter()) {
         JSAutoCompartment ac(cx, wrapper);
-        return SilentFailure(cx, id, "Property has accessor");
+        return SilentFailure(cx, id, "property has accessor");
     }
 
     // Apply extra scrutiny to objects.
     if (desc.value().isObject()) {
         RootedObject propObj(cx, js::UncheckedUnwrap(&desc.value().toObject()));
         JSAutoCompartment ac(cx, propObj);
 
         // Disallow non-subsumed objects.
         if (!AccessCheck::subsumes(target, propObj)) {
             JSAutoCompartment ac(cx, wrapper);
-            return SilentFailure(cx, id, "Value not same-origin with target");
+            return SilentFailure(cx, id, "value not same-origin with target");
         }
 
         // Disallow non-Xrayable objects.
         XrayType xrayType = GetXrayType(propObj);
         if (xrayType == NotXray || xrayType == XrayForOpaqueObject) {
             JSAutoCompartment ac(cx, wrapper);
-            return SilentFailure(cx, id, "Value not Xrayable");
+            return SilentFailure(cx, id, "value not Xrayable");
         }
 
         // Disallow callables.
         if (JS_ObjectIsCallable(cx, propObj)) {
             JSAutoCompartment ac(cx, wrapper);
-            return SilentFailure(cx, id, "Value is callable");
+            return SilentFailure(cx, id, "value is callable");
         }
     }
 
     // Disallow any property that shadows something on its (Xrayed)
     // prototype chain.
     JSAutoCompartment ac2(cx, wrapper);
     RootedObject proto(cx);
     bool foundOnProto = false;
     if (!JS_GetPrototype(cx, wrapper, &proto) ||
         (proto && !JS_HasPropertyById(cx, proto, id, &foundOnProto)))
     {
         return false;
     }
     if (foundOnProto)
-        return SilentFailure(cx, id, "Value shadows a property on the standard prototype");
+        return SilentFailure(cx, id, "value shadows a property on the standard prototype");
 
     // We made it! Assign over the descriptor, and don't forget to wrap.
     outDesc.assign(desc.get());
     return true;
 }
 
 bool
 JSXrayTraits::resolveOwnProperty(JSContext *cx, const Wrapper &jsWrapper,