Changeset 280931 in webkit
- Timestamp:
- Aug 11, 2021, 3:05:02 PM (5 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 3 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/http/tests/performance/performance-measure-fetch-start-expected.txt (added)
-
LayoutTests/http/tests/performance/performance-measure-fetch-start.html (added)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/page/PerformanceTiming.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r280928 r280931 1 2021-08-11 Alex Christensen <achristensen@webkit.org> 2 3 REGRESSION (r278392) performance.measure should never throw an InvalidAccessError for fetchStart 4 https://bugs.webkit.org/show_bug.cgi?id=229008 5 <rdar://79960877> 6 7 Reviewed by Chris Dumez. 8 9 * http/tests/performance/performance-measure-fetch-start-expected.txt: Added. 10 * http/tests/performance/performance-measure-fetch-start.html: Added. 11 1 12 2021-08-11 Dana Estra <destra@apple.com> 2 13 -
trunk/Source/WebCore/ChangeLog
r280930 r280931 1 2021-08-11 Alex Christensen <achristensen@webkit.org> 2 3 REGRESSION (r278392) performance.measure should never throw an InvalidAccessError for fetchStart 4 https://bugs.webkit.org/show_bug.cgi?id=229008 5 <rdar://79960877> 6 7 Reviewed by Chris Dumez. 8 9 Test: http/tests/performance/performance-measure-fetch-start.html 10 11 PerformanceTiming::fetchStart is returning 0 when we get a main resource from the cache sometimes. 12 This is causing PerformanceUserTiming::convertMarkToTimestamp to throw an error, which it should. 13 Like PerformanceResourceTiming::fetchStart we need to fall back to ResourceLoadTiming::startTime 14 if the NetworkLoadMetrics doesn't have any useful data for us. 15 16 * page/PerformanceTiming.cpp: 17 (WebCore::PerformanceTiming::fetchStart const): 18 1 19 2021-08-11 John Wilander <wilander@apple.com> 2 20 -
trunk/Source/WebCore/page/PerformanceTiming.cpp
r280454 r280931 138 138 139 139 auto* metrics = networkLoadMetrics(); 140 if (!metrics) 141 return 0; 142 143 m_fetchStart = monotonicTimeToIntegerMilliseconds(metrics->fetchStart); 140 if (metrics) 141 m_fetchStart = monotonicTimeToIntegerMilliseconds(metrics->fetchStart); 142 143 if (!m_fetchStart) { 144 if (auto* timing = documentLoadTiming()) 145 m_fetchStart = monotonicTimeToIntegerMilliseconds(timing->startTime()); 146 } 147 148 // Like PerformanceResourceTiming::fetchStart, fetchStart is a required property 149 ASSERT(m_fetchStart); 144 150 return m_fetchStart; 145 151 }
Note:
See TracChangeset
for help on using the changeset viewer.