Home
last modified time | relevance | path

Searched refs:source_file (Results 1 – 4 of 4) sorted by relevance

/bootable/recovery/applypatch/
Dapplypatch.cpp49 static bool GenerateTarget(const Partition& target, const FileContents& source_file,
258 FileContents source_file; in PatchPartitionCheck() local
260 ReadPartitionToBuffer(source, &source_file, true)); in PatchPartitionCheck()
281 FileContents source_file; in PatchPartition() local
282 if (ReadPartitionToBuffer(source, &source_file, backup_source)) { in PatchPartition()
283 return GenerateTarget(target, source_file, patch, bonus, backup_source); in PatchPartition()
302 FileContents source_file; in FlashPartition() local
303 if (!LoadFileContents(source_filename, &source_file)) { in FlashPartition()
314 if (memcmp(source_file.sha1, expected_sha1, SHA_DIGEST_LENGTH) != 0) { in FlashPartition()
318 << ", found: " << short_sha1(source_file.sha1); in FlashPartition()
[all …]
Dapplypatch_modes.cpp48 static int FlashMode(const std::string& target_emmc, const std::string& source_file) { in FlashMode() argument
55 return FlashPartition(target, source_file) ? 0 : 1; in FlashMode()
/bootable/recovery/tests/unit/
Dapplypatch_test.cpp49 source_file = from_testdata_base("boot.img"); in SetUp()
51 ASSERT_TRUE(LoadFileContents(source_file, &boot_fc)); in SetUp()
61 source_partition = Partition(source_file, source_size, source_sha1); in SetUp()
76 std::string source_file; member in ApplyPatchTest
100 ASSERT_FALSE(CheckPartition(Partition(source_file, target_size, target_sha1))); in TEST_F()
101 ASSERT_FALSE(CheckPartition(Partition(source_file, source_size, bad_sha1_a))); in TEST_F()
103 ASSERT_FALSE(CheckPartition(Partition(source_file, source_size - 1, source_sha1))); in TEST_F()
104 ASSERT_FALSE(CheckPartition(Partition(source_file, source_size + 1, source_sha1))); in TEST_F()
111 PatchPartitionCheck(Partition(source_file, source_size - 1, source_sha1), source_partition)); in TEST_F()
114 PatchPartitionCheck(Partition(source_file, source_size + 1, source_sha1), source_partition)); in TEST_F()
[all …]
Dupdater_test.cpp255 std::string source_file = from_testdata_base("boot.img"); in TEST_F() local
257 ASSERT_TRUE(android::base::ReadFileToString(source_file, &source_content)); in TEST_F()
260 Partition source(source_file, source_size, source_hash); in TEST_F()
284 Partition bad_source(source_file, source_size + 1, source_hash); in TEST_F()