Bug 186369 - Add logging around internalError(const URL&)
Summary: Add logging around internalError(const URL&)
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Keith Rollin
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-06-06 16:09 PDT by Keith Rollin
Modified: 2018-06-11 15:52 PDT (History)
8 users (show)

See Also:


Attachments
Patch (5.74 KB, patch)
2018-06-06 16:12 PDT, Keith Rollin
no flags Details | Formatted Diff | Diff
Fix build error (5.80 KB, patch)
2018-06-06 16:46 PDT, Keith Rollin
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Keith Rollin 2018-06-06 16:09:25 PDT
There are times when we receive bug reports where the user says that they are simply shown a page saying an internal error occurred. To help understand the circumstances of that error, add some logging to internalError() in WebErrors.cpp. This logging logs at the Error level that internalError() was called and then logs a backtrace.
Comment 1 Radar WebKit Bug Importer 2018-06-06 16:09:48 PDT
<rdar://problem/40872046>
Comment 2 Keith Rollin 2018-06-06 16:12:48 PDT
Created attachment 342090 [details]
Patch
Comment 3 Keith Rollin 2018-06-06 16:46:25 PDT
Created attachment 342094 [details]
Fix build error
Comment 4 Brent Fulgham 2018-06-11 14:27:45 PDT
Comment on attachment 342094 [details]
Fix build error

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

Looks good! I suggest the modern C++ loop.

> Source/WTF/wtf/Assertions.cpp:556
> +        for (int frameNumber = 1; frameNumber < stackTrace->size(); ++frameNumber) {

Could this be a modern C++ loop?

for (auto stackFrame : stackTrace->stack()) {
   ...
Comment 5 Brent Fulgham 2018-06-11 15:25:40 PDT
(In reply to Brent Fulgham from comment #4)
> Comment on attachment 342094 [details]
> Fix build error
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=342094&action=review
> 
> Looks good! I suggest the modern C++ loop.
> 
> > Source/WTF/wtf/Assertions.cpp:556
> > +        for (int frameNumber = 1; frameNumber < stackTrace->size(); ++frameNumber) {
> 
> Could this be a modern C++ loop?
> 
> for (auto stackFrame : stackTrace->stack()) {
>    ...

I spoke with Keith in person, and realized that we need the index for logging. So never mind!
Comment 6 WebKit Commit Bot 2018-06-11 15:52:30 PDT
Comment on attachment 342094 [details]
Fix build error

Clearing flags on attachment: 342094

Committed r232734: <https://trac.webkit.org/changeset/232734>
Comment 7 WebKit Commit Bot 2018-06-11 15:52:32 PDT
All reviewed patches have been landed.  Closing bug.