Title: [260515] trunk/Tools
- Revision
- 260515
- Author
- sbar...@apple.com
- Date
- 2020-04-22 09:22:38 -0700 (Wed, 22 Apr 2020)
Log Message
makeValueRefForValue should be robust against the type encoding of a NSNumber backed by a boolean
https://bugs.webkit.org/show_bug.cgi?id=210821
<rdar://problem/62136598>
Reviewed by Tim Horton.
* DumpRenderTree/mac/AccessibilityNotificationHandler.mm:
(makeValueRefForValue):
Modified Paths
Diff
Modified: trunk/Tools/ChangeLog (260514 => 260515)
--- trunk/Tools/ChangeLog 2020-04-22 16:22:07 UTC (rev 260514)
+++ trunk/Tools/ChangeLog 2020-04-22 16:22:38 UTC (rev 260515)
@@ -1,3 +1,14 @@
+2020-04-22 Saam Barati <sbar...@apple.com>
+
+ makeValueRefForValue should be robust against the type encoding of a NSNumber backed by a boolean
+ https://bugs.webkit.org/show_bug.cgi?id=210821
+ <rdar://problem/62136598>
+
+ Reviewed by Tim Horton.
+
+ * DumpRenderTree/mac/AccessibilityNotificationHandler.mm:
+ (makeValueRefForValue):
+
2020-04-21 Ryan Haddad <ryanhad...@apple.com>
Unreviewed, reverting r260410.
Modified: trunk/Tools/DumpRenderTree/mac/AccessibilityNotificationHandler.mm (260514 => 260515)
--- trunk/Tools/DumpRenderTree/mac/AccessibilityNotificationHandler.mm 2020-04-22 16:22:07 UTC (rev 260514)
+++ trunk/Tools/DumpRenderTree/mac/AccessibilityNotificationHandler.mm 2020-04-22 16:22:38 UTC (rev 260515)
@@ -106,7 +106,7 @@
if ([value isKindOfClass:[NSString class]])
return JSValueMakeString(context, [value createJSStringRef].get());
if ([value isKindOfClass:[NSNumber class]]) {
- if (!strcmp([value objCType], @encode(BOOL)))
+ if (!strcmp([value objCType], @encode(BOOL)) || !strcmp([value objCType], "c"))
return JSValueMakeBoolean(context, [value boolValue]);
return JSValueMakeNumber(context, [value doubleValue]);
}
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes