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

Issue 1766613002: Revert of Replace std::string::find with base::StartsWith when comparing cookie paths. (Closed)

Created:
4 years, 9 months ago by benwells
Modified:
4 years, 9 months ago
Reviewers:
Mike West, mmenke
CC:
cbentzel+watch_chromium.org, chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Revert of Replace std::string::find with base::StartsWith when comparing cookie paths. (patchset #5 id:100001 of https://codereview.chromium.org/1746303002/ ) Reason for revert: This CL seems to have caused a cookie test to fail on the Mac valgrind bot. As it is a test failure, not memory error, being reported I think it is worth investigating. See https://build.chromium.org/p/chromium.memory.fyi/builders/Chromium%20Mac%20%28valgrind%29%282%29/builds/37976. Sample bot output: CookieMonsterTest.PersisentCookieStorageTest: ../../net/cookies/cookie_monster_unittest.cc:2371: Failure Value of: store->commands().size() Actual: 6 Expected: 5u Which is: 5 Original issue's description: > Replace std::string::find with base::StartsWith when comparing cookie paths. > > The old code was correct, and the performance benefits are minimal, but > "path1.find(path2) != 0" is a bit obscure. > > Also switch DeleteCookie to CanonicalCookie::IsOnPath to compare cookies, > to match normal cookie semantics. > > BUG=583482 > > Committed: https://crrev.com/23b6717eac3a002b02aa9951d62bec2b641fe947 > Cr-Commit-Position: refs/heads/master@{#379092} TBR=mkwst@chromium.org,mmenke@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=583482 Committed: https://crrev.com/3e32f97dfa5c21eef32c1bdca055752284218959 Cr-Commit-Position: refs/heads/master@{#379216}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+37 lines, -45 lines) Patch
M net/cookies/canonical_cookie.cc View 3 chunks +11 lines, -12 lines 0 comments Download
M net/cookies/cookie_monster.cc View 1 chunk +5 lines, -4 lines 0 comments Download
M net/cookies/cookie_monster_unittest.cc View 1 chunk +21 lines, -0 lines 0 comments Download
M net/cookies/cookie_store_unittest.h View 2 chunks +0 lines, -29 lines 0 comments Download

Messages

Total messages: 6 (2 generated)
benwells
Created Revert of Replace std::string::find with base::StartsWith when comparing cookie paths.
4 years, 9 months ago (2016-03-04 05:00:03 UTC) #1
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1766613002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1766613002/1
4 years, 9 months ago (2016-03-04 05:00:27 UTC) #2
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years, 9 months ago (2016-03-04 05:00:54 UTC) #4
commit-bot: I haz the power
4 years, 9 months ago (2016-03-04 05:02:39 UTC) #6
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/3e32f97dfa5c21eef32c1bdca055752284218959
Cr-Commit-Position: refs/heads/master@{#379216}

Powered by Google App Engine
This is Rietveld 408576698