Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(15)

Issue 2535183002: Revert of Handle empty string in GetSavePasswordDialogTitleTextAndLinkRange gracefully (Closed)

Created:
4 years ago by vabr (Chromium)
Modified:
4 years ago
Reviewers:
CC:
chromium-reviews
Target Ref:
refs/pending/branch-heads/2883
Project:
chromium
Visibility:
Public.

Description

Revert of Handle empty string in GetSavePasswordDialogTitleTextAndLinkRange gracefully (patchset #1 id:1 of https://codereview.chromium.org/2534113002/ ) Reason for revert: Compile failure. BUG=669394 Original issue's description: > Handle empty string in GetSavePasswordDialogTitleTextAndLinkRange gracefully > > GetSavePasswordDialogTitleTextAndLinkRange currently assumes that localised > strings for particular IDs contain placeholders, and attempts to access the > vector of offsets corresponding to such placeholders. However, in some > situations (http://crbug.com/658902#c18) the localised string may be empty. > This led to an out-of-bounds access and crash on Android. > > This CL is the smallest change to handle such situation gracefully -- it checks > the length of the vector with offsets and gives up accessing it if it is empty. > This avoids the crash but results in displaying a UI with empty strings. > Ideally, the UI would also be supressed on these occasions, but that is left > for follow-up CLs. The current situation is already an improvement (password > manager is still not very useful, but at least the browser has a chance to > continue). > > The CL also removes the temporary logging put in for the crash investigation. > > BUG=658902 > > Review-Url: https://codereview.chromium.org/2526283002 > Cr-Commit-Position: refs/heads/master@{#434482} > (cherry picked from commit 49ebcf7d64e71c7d3ac71bca66f65d61180bfb8c) > > Committed: https://chromium.googlesource.com/chromium/src/+/910f52d5209148d0ad1afa8cbfb9360d65fcb00e TBR= # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=658902

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+2 lines, -84 lines) Patch
M chrome/browser/ui/passwords/manage_passwords_view_utils.cc View 1 chunk +2 lines, -7 lines 0 comments Download
M chrome/browser/ui/passwords/manage_passwords_view_utils_unittest.cc View 2 chunks +0 lines, -77 lines 0 comments Download

Messages

Total messages: 6 (3 generated)
vabr (Chromium)
Created Revert of Handle empty string in GetSavePasswordDialogTitleTextAndLinkRange gracefully
4 years ago (2016-11-29 08:11:12 UTC) #2
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2535183002/1
4 years ago (2016-11-29 08:11:40 UTC) #3
commit-bot: I haz the power
4 years ago (2016-11-29 08:15:45 UTC) #6
Message was sent while issue was closed.
Committed patchset #1 (id:1)

Powered by Google App Engine
This is Rietveld 408576698