Bug 28802 - Remove ASSERT(frame) in ResourceHandle::start (ResourceHandleCurl.cpp)
Summary: Remove ASSERT(frame) in ResourceHandle::start (ResourceHandleCurl.cpp)
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: 528+ (Nightly build)
Hardware: Other Other
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-08-28 03:18 PDT by Kwang Yul Seo
Modified: 2009-08-31 03:45 PDT (History)
2 users (show)

See Also:


Attachments
Remove ASSERT(frame) (1.72 KB, patch)
2009-08-28 03:25 PDT, Kwang Yul Seo
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kwang Yul Seo 2009-08-28 03:18:43 PDT
bool ResourceHandle::start(Frame* frame)
{
    ASSERT(frame);
    ResourceHandleManager::sharedInstance()->add(this);
    return true;
}

Remove ASSERT in the first line because the frame could be null if the ResourceHandle is not associated with any frame, e.g. if we are downloading a file.

ResourceHandleSoup.cpp handles this case. Follow what ResourceHandleSoup.cpp does.
Comment 1 Kwang Yul Seo 2009-08-28 03:25:29 PDT
Created attachment 38726 [details]
Remove ASSERT(frame)

Follow what ResourceHandleSoup does.
Comment 2 Eric Seidel (no email) 2009-08-31 03:32:37 PDT
Comment on attachment 38726 [details]
Remove ASSERT(frame)

Mac has:
    if (!frame)
        return false;

Win does:
    // If we are no longer attached to a Page, this must be an attempted load from an
    // onUnload handler, so let's just block it.
    if (!frame->page())
        return false;

Somebody is wrong here.  I'll CC bradee.
Comment 3 Eric Seidel (no email) 2009-08-31 03:33:51 PDT
Brady, see comment above about discrepancy between Mac/Win.
Comment 4 Eric Seidel (no email) 2009-08-31 03:45:15 PDT
Comment on attachment 38726 [details]
Remove ASSERT(frame)

Clearing flags on attachment: 38726

Committed r47888: <http://trac.webkit.org/changeset/47888>
Comment 5 Eric Seidel (no email) 2009-08-31 03:45:18 PDT
All reviewed patches have been landed.  Closing bug.