Bug 1640412 - Include failure id for status=unavailable/blocked too. r=aosmond
authorJeff Muizelaar <jmuizelaar@mozilla.com>
Mon, 25 May 2020 12:42:12 +0000
changeset 531905 df5bfb667b9d2fee068861b5c6129bcbbff95cce
parent 531904 9c52c330dd88edf25b46c77a4d79cdfa5dcc2456
child 531906 0a269ce5b1dacc22b4d541d1633bbb2a31483b7d
push id37448
push userncsoregi@mozilla.com
push dateMon, 25 May 2020 21:44:09 +0000
treeherdermozilla-central@df5bfb667b9d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersaosmond
bugs1640412
milestone78.0a1
first release with
nightly linux32
df5bfb667b9d / 78.0a1 / 20200525214409 / files
nightly linux64
df5bfb667b9d / 78.0a1 / 20200525214409 / files
nightly mac
df5bfb667b9d / 78.0a1 / 20200525214409 / files
nightly win32
df5bfb667b9d / 78.0a1 / 20200525214409 / files
nightly win64
df5bfb667b9d / 78.0a1 / 20200525214409 / files
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
releases
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1640412 - Include failure id for status=unavailable/blocked too. r=aosmond We get a fair amount of this on modern hardware. It would be good to know why. Differential Revision: https://phabricator.services.mozilla.com/D76605
widget/GfxInfoBase.cpp
--- a/widget/GfxInfoBase.cpp
+++ b/widget/GfxInfoBase.cpp
@@ -1634,22 +1634,25 @@ bool GfxInfoBase::InitFeatureObject(JSCo
                                     mozilla::gfx::FeatureState& aFeatureState,
                                     JS::MutableHandle<JSObject*> aOutObj) {
   JS::Rooted<JSObject*> obj(aCx, JS_NewPlainObject(aCx));
   if (!obj) {
     return false;
   }
 
   nsCString status;
-  if (aFeatureState.GetValue() == FeatureStatus::Blacklisted) {
+  auto value = aFeatureState.GetValue();
+  if (value == FeatureStatus::Blacklisted ||
+      value == FeatureStatus::Unavailable ||
+      value == FeatureStatus::Blocked) {
     status.AppendPrintf("%s:%s",
-                        FeatureStatusToString(aFeatureState.GetValue()),
+                        FeatureStatusToString(value),
                         aFeatureState.GetFailureId().get());
   } else {
-    status.Append(FeatureStatusToString(aFeatureState.GetValue()));
+    status.Append(FeatureStatusToString(value));
   }
 
   JS::Rooted<JSString*> str(aCx, JS_NewStringCopyZ(aCx, status.get()));
   JS::Rooted<JS::Value> val(aCx, JS::StringValue(str));
   JS_SetProperty(aCx, obj, "status", val);
 
   // Add the feature object to the container.
   {