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

Issue 155560: Don't use ID generation logic always. Only reassign IDs... (Closed)

Created:
11 years, 5 months ago by Munjal (Google)
Modified:
9 years ago
CC:
chromium-reviews_googlegroups.com, Ben Goodger (Google)
Visibility:
Public.

Description

Don't use ID generation logic always. Only reassign IDs when checksums differ or if IDs are missing and do that simply by assigning the next maximum id. Add a unit test. BUG=16357 TEST=NONE Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=20779

Patch Set 1 #

Total comments: 28

Patch Set 2 : '' #

Patch Set 3 : '' #

Total comments: 4

Patch Set 4 : '' #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+94 lines, -195 lines) Patch
M chrome/browser/bookmarks/bookmark_codec.h View 1 2 5 chunks +12 lines, -37 lines 0 comments Download
M chrome/browser/bookmarks/bookmark_codec.cc View 1 2 3 7 chunks +31 lines, -69 lines 1 comment Download
M chrome/browser/bookmarks/bookmark_codec_unittest.cc View 1 3 chunks +51 lines, -89 lines 0 comments Download

Messages

Total messages: 11 (0 generated)
Munjal (Google)
11 years, 5 months ago (2009-07-15 08:24:37 UTC) #1
sky
http://codereview.chromium.org/155560/diff/1/3 File chrome/browser/bookmarks/bookmark_codec.cc (right): http://codereview.chromium.org/155560/diff/1/3#newcode264 Line 264: void BookmarkCodec::ReassignIDs(BookmarkNode* bb_node, As not having ids is ...
11 years, 5 months ago (2009-07-15 15:47:34 UTC) #2
Erik does not do reviews
http://codereview.chromium.org/155560/diff/1/3 File chrome/browser/bookmarks/bookmark_codec.cc (right): http://codereview.chromium.org/155560/diff/1/3#newcode76 Line 76: if (ids_missing_ || computed_checksum() != stored_checksum()) { If ...
11 years, 5 months ago (2009-07-15 16:13:32 UTC) #3
Munjal (Google)
http://codereview.chromium.org/155560/diff/1/3 File chrome/browser/bookmarks/bookmark_codec.cc (right): http://codereview.chromium.org/155560/diff/1/3#newcode76 Line 76: if (ids_missing_ || computed_checksum() != stored_checksum()) { On ...
11 years, 5 months ago (2009-07-15 18:21:19 UTC) #4
sky
Again, I don't think many users are going to manually change their file. If the ...
11 years, 5 months ago (2009-07-15 18:34:48 UTC) #5
munjal1
Done. Can you take a quick look again? On Wed, Jul 15, 2009 at 11:34 ...
11 years, 5 months ago (2009-07-15 19:12:59 UTC) #6
sky
LGTM with the following changes. http://codereview.chromium.org/155560/diff/20/22 File chrome/browser/bookmarks/bookmark_codec.cc (right): http://codereview.chromium.org/155560/diff/20/22#newcode185 Line 185: if (value.GetString(kIdKey, &id_string)) ...
11 years, 5 months ago (2009-07-15 19:27:38 UTC) #7
Munjal (Google)
http://codereview.chromium.org/155560/diff/20/22 File chrome/browser/bookmarks/bookmark_codec.cc (right): http://codereview.chromium.org/155560/diff/20/22#newcode185 Line 185: if (value.GetString(kIdKey, &id_string)) { On 2009/07/15 19:27:38, sky ...
11 years, 5 months ago (2009-07-15 19:36:37 UTC) #8
sky
LGTM
11 years, 5 months ago (2009-07-15 19:43:15 UTC) #9
Erik does not do reviews
depending on Scott's reply here, LGTM http://codereview.chromium.org/155560/diff/27/1008 File chrome/browser/bookmarks/bookmark_codec.cc (right): http://codereview.chromium.org/155560/diff/27/1008#newcode259 Line 259: ReassignIDsHelper(bb_node); Are ...
11 years, 5 months ago (2009-07-15 19:44:52 UTC) #10
sky
11 years, 5 months ago (2009-07-15 19:57:48 UTC) #11
On Wed, Jul 15, 2009 at 12:44 PM, <erikkay@chromium.org> wrote:
> depending on Scott's reply here, LGTM
>
>
>
> http://codereview.chromium.org/155560/diff/27/1008
> File chrome/browser/bookmarks/bookmark_codec.cc (right):
>
> http://codereview.chromium.org/155560/diff/27/1008#newcode259
> Line 259: ReassignIDsHelper(bb_node);
> Are there (or should there be) any assumptions about the ids of bb_node
> and other_node? =A0At initial creation time, these will have an id of 1
> and 2 respectively, but in this new code that isn't true. =A0Scott, do yo=
u
> think this is an issue?

That assumption was removed a long time ago. Changing the id of the
bookmark/other node shouldn't cause problems.

  -Scott

Powered by Google App Engine
This is Rietveld 408576698