Bug 202735 - MediaTime pretty printer can print if time is invalid
Summary: MediaTime pretty printer can print if time is invalid
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Xabier Rodríguez Calvar
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-10-09 02:15 PDT by Xabier Rodríguez Calvar
Modified: 2019-10-11 01:22 PDT (History)
14 users (show)

See Also:


Attachments
Patch (1.21 KB, patch)
2019-10-09 02:16 PDT, Xabier Rodríguez Calvar
no flags Details | Formatted Diff | Diff
Patch (1.64 KB, patch)
2019-10-10 05:06 PDT, Xabier Rodríguez Calvar
no flags Details | Formatted Diff | Diff
Patch for landing (1.64 KB, patch)
2019-10-10 05:07 PDT, Xabier Rodríguez Calvar
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Xabier Rodríguez Calvar 2019-10-09 02:15:23 PDT
MediaTime pretty printer can print if time is invalid
Comment 1 Xabier Rodríguez Calvar 2019-10-09 02:16:50 PDT
Created attachment 380522 [details]
Patch
Comment 2 Eric Carlson 2019-10-09 08:41:53 PDT
Comment on attachment 380522 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=380522&action=review

> Source/WTF/wtf/MediaTime.cpp:598
> +    if (isInvalid())
> +        builder.appendLiteral(", invalid");

It would be nice to fix MediaTime::toJSONObject as well. Something like:

if (isInvalid())
    object->setBoolean("invalid"_s, true);
Comment 3 Xabier Rodríguez Calvar 2019-10-10 05:06:07 PDT
Created attachment 380634 [details]
Patch
Comment 4 Xabier Rodríguez Calvar 2019-10-10 05:07:23 PDT
Created attachment 380635 [details]
Patch for landing
Comment 5 Xabier Rodríguez Calvar 2019-10-10 06:58:21 PDT
Comment on attachment 380635 [details]
Patch for landing

I'll land this tomorrow in the morning.
Comment 6 WebKit Commit Bot 2019-10-11 01:21:09 PDT
Comment on attachment 380635 [details]
Patch for landing

Clearing flags on attachment: 380635

Committed r251003: <https://trac.webkit.org/changeset/251003>
Comment 7 WebKit Commit Bot 2019-10-11 01:21:11 PDT
All reviewed patches have been landed.  Closing bug.
Comment 8 Radar WebKit Bug Importer 2019-10-11 01:22:19 PDT
<rdar://problem/56184195>