• mpearson@chromium.org's avatar
    Omnibox: Possibly Fix Rare OpenMatch Crash · 3ac64f2c
    mpearson@chromium.org authored
    The associated bug seems to imply a crash on this line
    ClassifyPage(controller_->GetWebContents()->GetURL())
    in OmniboxEditModel::OpenMatch().
    
    This change corrects the part of the test that may fail
    (if there's no active tab for some reason).
    I think controller_ is always valid (the rest of the edit
    model code use it without testing it for non-NULL).
    But I see at least two places in OmniboxEditModel that
    test for the non-NULLness of controller_->GetWebContents().
    Hence, I think it might be able to be NULL, so this
    change adds a test for it here too.
    
    TEST=new code compiles
    BUG=142931
    
    
    Review URL: https://chromiumcodereview.appspot.com/12250014
    
    git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182244 0039d316-1c4b-4281-b951-d872f2087c98
    3ac64f2c
omnibox_edit_model.cc 55.2 KB