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

Unified Diff: generate_delta_main.cc

Issue 3550020: AU: support for generating new style full updates. (Closed) Base URL: ssh://git@chromiumos-git/update_engine.git
Patch Set: fixes for review Created 10 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « delta_performer_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: generate_delta_main.cc
diff --git a/generate_delta_main.cc b/generate_delta_main.cc
index ab05c77c0d5335f2e18e636a6d76a9e49eefad65..c66d9d1026f74a85665ebf6b6b83ced823ced160 100644
--- a/generate_delta_main.cc
+++ b/generate_delta_main.cc
@@ -92,17 +92,20 @@ int Main(int argc, char** argv) {
LOG(INFO) << "done applying delta.";
return 0;
}
- CHECK(!FLAGS_old_dir.empty());
- CHECK(!FLAGS_new_dir.empty());
- CHECK(!FLAGS_old_image.empty());
CHECK(!FLAGS_new_image.empty());
CHECK(!FLAGS_out_file.empty());
- CHECK(!FLAGS_old_kernel.empty());
CHECK(!FLAGS_new_kernel.empty());
- if ((!IsDir(FLAGS_old_dir.c_str())) || (!IsDir(FLAGS_new_dir.c_str()))) {
- LOG(FATAL) << "old_dir or new_dir not directory";
+ if (FLAGS_old_image.empty()) {
+ LOG(INFO) << "Generating full update";
+ } else {
+ LOG(INFO) << "Generating delta update";
+ CHECK(!FLAGS_old_kernel.empty());
+ CHECK(!FLAGS_old_dir.empty());
+ CHECK(!FLAGS_new_dir.empty());
+ if ((!IsDir(FLAGS_old_dir.c_str())) || (!IsDir(FLAGS_new_dir.c_str()))) {
+ LOG(FATAL) << "old_dir or new_dir not directory";
+ }
}
-
DeltaDiffGenerator::GenerateDeltaUpdateFile(FLAGS_old_dir,
FLAGS_old_image,
FLAGS_new_dir,
« no previous file with comments | « delta_performer_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698