Check the results from applypatch am: 31f8cc84cf
am: d0dcbddd31
Change-Id: I00439aae8f79b0e2a5f7de6566110240492b526a
This commit is contained in:
+10
-4
@@ -1264,11 +1264,17 @@ static int PerformCommandDiff(CommandParameters& params) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (params.cmdname[0] == 'i') { // imgdiff
|
if (params.cmdname[0] == 'i') { // imgdiff
|
||||||
ApplyImagePatch(params.buffer.data(), blocks * BLOCKSIZE, &patch_value,
|
if (ApplyImagePatch(params.buffer.data(), blocks * BLOCKSIZE, &patch_value,
|
||||||
&RangeSinkWrite, &rss, nullptr, nullptr);
|
&RangeSinkWrite, &rss, nullptr, nullptr) != 0) {
|
||||||
|
fprintf(stderr, "Failed to apply image patch.\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
ApplyBSDiffPatch(params.buffer.data(), blocks * BLOCKSIZE, &patch_value, 0,
|
if (ApplyBSDiffPatch(params.buffer.data(), blocks * BLOCKSIZE, &patch_value,
|
||||||
&RangeSinkWrite, &rss, nullptr);
|
0, &RangeSinkWrite, &rss, nullptr) != 0) {
|
||||||
|
fprintf(stderr, "Failed to apply bsdiff patch.\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// We expect the output of the patcher to fill the tgt ranges exactly.
|
// We expect the output of the patcher to fill the tgt ranges exactly.
|
||||||
|
|||||||
Reference in New Issue
Block a user