• Matthew Mourgos's avatar
    Fix clipboard nudge related crash · d696ff54
    Matthew Mourgos authored
    Crash can be triggered from login screen when any paste is performed and
    ClipboardNudgeController::OnClipboardDataRead is called. So add a check
    to see that the clipboard history is enabled in the current mode.
    
    Also possible is that ClipboardNudgeController::ShouldShowNudge() is
    passed a null PrefService*. So add a check for this being null, as well
    as some checks for null dictionaries.
    
    Bug: 1150168
    Change-Id: I79e407f3896408af7a44aacf31f15d290c2629c6
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2546085
    Commit-Queue: Matthew Mourgos <mmourgos@chromium.org>
    Reviewed-by: default avatarAlex Newcomer <newcomer@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#828866}
    d696ff54
clipboard_history_util.cc 4.12 KB