Code: void AutofillExternalDelegate::OnSuggestionsReturned(
    int query_id,
    const std::vector<Suggestion>& input_suggestions,
    bool autoselect_first_suggestion,
    bool is_all_server_suggestions) {
  if (query_id != query_id_)
    return;

  std::vector<Suggestion> suggestions(input_suggestions);

   PossiblyRemoveAutofillWarnings(&suggestions);
 
#if !defined(OS_ANDROID)
  if (!suggestions.empty() && !features::ShouldUseNativeViews()) {
    suggestions.push_back(Suggestion());
    suggestions.back().frontend_id = POPUP_ITEM_ID_SEPARATOR;
  }
#endif
   if (should_show_scan_credit_card_) {
     Suggestion scan_credit_card(
         l10n_util::GetStringUTF16(IDS_AUTOFILL_SCAN_CREDIT_CARD));
    scan_credit_card.frontend_id = POPUP_ITEM_ID_SCAN_CREDIT_CARD;
    scan_credit_card.icon = base::ASCIIToUTF16("scanCreditCardIcon");
    suggestions.push_back(scan_credit_card);
  }

  has_autofill_suggestions_ = false;
  for (size_t i = 0; i < suggestions.size(); ++i) {
    if (suggestions[i].frontend_id > 0) {
      has_autofill_suggestions_ = true;
      break;
    }
  }

  if (should_show_cards_from_account_option_) {
    suggestions.emplace_back(
        l10n_util::GetStringUTF16(IDS_AUTOFILL_SHOW_ACCOUNT_CARDS));
    suggestions.back().frontend_id = POPUP_ITEM_ID_SHOW_ACCOUNT_CARDS;
    suggestions.back().icon = base::ASCIIToUTF16("google");
  }

  if (has_autofill_suggestions_)
    ApplyAutofillOptions(&suggestions, is_all_server_suggestions);

   if (suggestions.empty() && should_show_cc_signin_promo_) {
#if !defined(OS_ANDROID)
    if (has_autofill_suggestions_) {
      suggestions.push_back(Suggestion());
      suggestions.back().frontend_id = POPUP_ITEM_ID_SEPARATOR;
    }
#endif
     Suggestion signin_promo_suggestion(
         l10n_util::GetStringUTF16(IDS_AUTOFILL_CREDIT_CARD_SIGNIN_PROMO));
     signin_promo_suggestion.frontend_id =
        POPUP_ITEM_ID_CREDIT_CARD_SIGNIN_PROMO;
    suggestions.push_back(signin_promo_suggestion);
    signin_metrics::RecordSigninImpressionUserActionForAccessPoint(
         signin_metrics::AccessPoint::ACCESS_POINT_AUTOFILL_DROPDOWN);
   }
 
#if !defined(OS_ANDROID)
  if (!suggestions.empty() &&
      suggestions.back().frontend_id == POPUP_ITEM_ID_SEPARATOR) {
    suggestions.pop_back();
  }
#endif
  InsertDataListValues(&suggestions);

  if (suggestions.empty()) {
    manager_->client()->HideAutofillPopup();
    return;
  }

  if (query_field_.is_focusable) {
    manager_->client()->ShowAutofillPopup(
        element_bounds_, query_field_.text_direction, suggestions,
        autoselect_first_suggestion, GetWeakPtr());
  }
}

Vulnerability Type: 
CWE ID: CWE-416
Summary: Blink in Google Chrome prior to 54.0.2840.59 for Windows, Mac, and Linux; 54.0.2840.85 for Android incorrectly allowed reentrance of FrameView::updateLifecyclePhasesInternal(), which allowed a remote attacker to perform an out of bounds memory read via crafted HTML pages.
Commit Message: [Autofill] Remove AutofillPopupViewViews and associated feature.

Bug: 906135,831603
Change-Id: I3c982f8b3ffb4928c7c878e74e10113999106499
Reviewed-on: https://chromium-review.googlesource.com/c/1387124
Reviewed-by: Robert Kaplow <rkaplow@chromium.org>
Reviewed-by: Vasilii Sukhanov <vasilii@chromium.org>
Reviewed-by: Fabio Tirelo <ftirelo@chromium.org>
Reviewed-by: Tommy Martino <tmartino@chromium.org>
Commit-Queue: Mathieu Perreault <mathp@chromium.org>
Cr-Commit-Position: refs/heads/master@{#621360}