Bug 71980 - Remove unneeded frame check in FrameView::detachCustomScrollbars
Summary: Remove unneeded frame check in FrameView::detachCustomScrollbars
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Frames (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Julien Chaffraix
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-09 17:48 PST by Julien Chaffraix
Modified: 2011-11-11 14:01 PST (History)
2 users (show)

See Also:


Attachments
Trivial change: remove the check. (1.35 KB, patch)
2011-11-09 17:52 PST, Julien Chaffraix
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Julien Chaffraix 2011-11-09 17:48:50 PST
Looks like this is a left-over from several refactorings that changed the function.

The remainder of detachCustomScrollbars definitely does not care about having a Frame.

Patch forthcoming.
Comment 1 Julien Chaffraix 2011-11-09 17:52:19 PST
Created attachment 114412 [details]
Trivial change: remove the check.
Comment 2 Anders Carlsson 2011-11-10 12:15:40 PST
Comment on attachment 114412 [details]
Trivial change: remove the check.

Can you remove this because m_frame is never going to be null, or because m_frame is never dereferenced? If it is because m_frame is never going to be null, you can assert that.
Comment 3 Julien Chaffraix 2011-11-10 16:54:32 PST
(In reply to comment #2)
> (From update of attachment 114412 [details])
> Can you remove this because m_frame is never going to be null, or because m_frame is never dereferenced? If it is because m_frame is never going to be null, you can assert that.

The latter I am afraid: AFAICT this check was introduced because we would crash if we did not check the Frame but the code has changed and this check is not needed anymore.
Comment 4 WebKit Review Bot 2011-11-11 14:01:42 PST
Comment on attachment 114412 [details]
Trivial change: remove the check.

Clearing flags on attachment: 114412

Committed r100014: <http://trac.webkit.org/changeset/100014>
Comment 5 WebKit Review Bot 2011-11-11 14:01:46 PST
All reviewed patches have been landed.  Closing bug.