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

Issue 2716005: Modify bsdiff 4.3 to goobsdiff, which is appropriate for use as the Mac binary differ/patcher (Closed)

Created:
10 years, 6 months ago by Mark Mentovai
Modified:
9 years, 7 months ago
Reviewers:
TVL
CC:
chromium-reviews, kuchhal
Visibility:
Public.

Description

Modify bsdiff 4.3 to create goobsdiff, which is appropriate for use as the Mac binary differ/patcher. BUG=45017 TEST=none Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=49316

Patch Set 1 #

Patch Set 2 : '' #

Total comments: 5

Patch Set 3 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+451 lines, -776 lines) Patch
M chrome/installer/mac/third_party/bsdiff/README.chromium View 1 1 chunk +39 lines, -2 lines 0 comments Download
D chrome/installer/mac/third_party/bsdiff/bsdiff.c View 1 chunk +0 lines, -404 lines 0 comments Download
D chrome/installer/mac/third_party/bsdiff/bspatch.c View 1 chunk +0 lines, -204 lines 0 comments Download
A + chrome/installer/mac/third_party/bsdiff/goobsdiff.c View 5 chunks +168 lines, -82 lines 0 comments Download
A chrome/installer/mac/third_party/bsdiff/goobsdiff.gyp View 1 chunk +36 lines, -0 lines 0 comments Download
A + chrome/installer/mac/third_party/bsdiff/goobspatch.c View 1 2 3 chunks +208 lines, -84 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
Mark Mentovai
10 years, 6 months ago (2010-06-09 19:53:42 UTC) #1
TVL
http://codereview.chromium.org/2716005/diff/7001/8004 File chrome/installer/mac/third_party/bsdiff/goobsdiff.c (right): http://codereview.chromium.org/2716005/diff/7001/8004#newcode366 chrome/installer/mac/third_party/bsdiff/goobsdiff.c:366: 91 5 unused you could sneak in a crc32 ...
10 years, 6 months ago (2010-06-09 20:43:01 UTC) #2
TVL
lg
10 years, 6 months ago (2010-06-09 21:04:14 UTC) #3
Mark Mentovai
10 years, 6 months ago (2010-06-09 21:06:50 UTC) #4
thomasvl@chromium.org wrote:
> http://codereview.chromium.org/2716005/diff/7001/8004#newcode366
> chrome/installer/mac/third_party/bsdiff/goobsdiff.c:366: 91     5
> unused
> you could sneak in a crc32 the rest of the headers and 3 payloads (so a
> patch can be validated, bzip/gzip provide crc for their chunks, but if
> you use uncompressed, they would be no check)

This is complex and I don’t believe it’s necessary but I could be
convinced if you feel strongly.

> http://codereview.chromium.org/2716005/diff/7001/8006#newcode81
> chrome/installer/mac/third_party/bsdiff/goobspatch.c:81: static void
> cfopen(cfile *cf, const char *path, off_t off,
> you could pass an "expectedLength" here, and store it in the struct as
> "bytesLeft" then in the cfread call, check to see if there are atleast
> that many bypes left and dec the count after the read.  This way you
> make sure no corruption makes you overread from within the file.  add a
> call like cfeof to confirm everything was read, and you can make sure
> there wasn't something extra when the blocks are done with their work.

This is difficult because the “expected” values are the lengths of the
encoded stream but the cfile interface deals in decoded/decompressed
lengths.

I’ve made the other changes.

Mark

Powered by Google App Engine
This is Rietveld 408576698