Home
last modified time | relevance | path

Searched refs:contents (Results 1 – 25 of 209) sorted by relevance

123456789

/system/extras/memory_replay/
DFile.cpp42 std::string contents; in ZipGetContents() local
47 contents.resize(entry.uncompressed_length); in ZipGetContents()
48 if (ExtractToMemory(archive, &entry, reinterpret_cast<uint8_t*>(contents.data()), in ZipGetContents()
50 contents = ""; in ZipGetContents()
56 return contents; in ZipGetContents()
92 std::string contents; in GetUnwindInfo() local
94 contents = ZipGetContents(filename); in GetUnwindInfo()
95 } else if (!android::base::ReadFileToString(filename, &contents)) { in GetUnwindInfo()
98 if (contents.empty()) { in GetUnwindInfo()
105 index = contents.find('\n', index); in GetUnwindInfo()
[all …]
/system/tools/aidl/tests/
Dfake_io_delegate.cpp47 unique_ptr<string> contents; in GetFileContents() local
50 return contents; in GetFileContents()
52 contents.reset(new string); in GetFileContents()
53 *contents = it->second; in GetFileContents()
54 contents->append(content_suffix); in GetFileContents()
56 return contents; in GetFileContents()
88 const string& contents) { in SetFileContents() argument
89 file_contents_[filename] = contents; in SetFileContents()
107 string contents; in AddStubParcelable() local
109 contents = StringPrintf("package %s;\nparcelable %s;", in AddStubParcelable()
[all …]
/system/core/libutils/
DSingleton_test2.cpp26 void singletonSetInstanceContents(unsigned int contents) { in singletonSetInstanceContents() argument
27 SingletonTestData::getInstance().contents = contents; in singletonSetInstanceContents()
31 return SingletonTestData::getInstance().contents; in singletonGetInstanceContents()
DSingleton_test1.cpp27 void singletonSetInstanceContents(unsigned int contents) { in singletonSetInstanceContents() argument
28 SingletonTestData::getInstance().contents = contents; in singletonSetInstanceContents()
32 return SingletonTestData::getInstance().contents; in singletonGetInstanceContents()
DFileMap_fuzz.cpp29 std::string contents = dataProvider.ConsumeRandomLengthString(MAX_STR_SIZE); in LLVMFuzzerTestOneInput() local
32 if (contents.length() > 0) { in LLVMFuzzerTestOneInput()
33 const char* bytes = contents.c_str(); in LLVMFuzzerTestOneInput()
/system/core/fs_mgr/libsnapshot/
Dsnapshot_stats.cpp35 std::string contents; in ReadState() local
36 if (!android::base::ReadFileToString(path_, &contents)) { in ReadState()
40 if (!report_.ParseFromString(contents)) { in ReadState()
48 std::string contents; in WriteState() local
49 if (!report_.SerializeToString(&contents)) { in WriteState()
53 if (!WriteStringToFileAtomic(contents, path_)) { in WriteState()
/system/update_engine/payload_consumer/
Dpartition_update_generator_android_unittest.cc55 void SetUpBlockDevice(const std::map<std::string, std::string>& contents) { in SetUpBlockDevice() argument
56 for (const auto& [name, content] : contents) { in SetUpBlockDevice()
99 std::map<std::string, std::string> contents = { in TEST_F() local
111 SetUpBlockDevice(contents); in TEST_F()
120 std::map<std::string, std::string> contents = { in TEST_F() local
126 SetUpBlockDevice(contents); in TEST_F()
142 std::map<std::string, std::string> contents = { in TEST_F() local
151 SetUpBlockDevice(contents); in TEST_F()
/system/linkerconfig/contents/tests/configuration/
Dapexconfig_test.cc52 android::linkerconfig::contents::Context ctx; in TEST_F()
54 auto config = android::linkerconfig::contents::CreateApexConfiguration( in TEST_F()
64 android::linkerconfig::contents::Context ctx; in TEST_F()
69 auto config = android::linkerconfig::contents::CreateApexConfiguration( in TEST_F()
Drecovery_test.cc22 using android::linkerconfig::contents::Context;
23 using android::linkerconfig::contents::CreateRecoveryConfiguration;
Dlegacy_test.cc22 using android::linkerconfig::contents::Context;
23 using android::linkerconfig::contents::CreateLegacyConfiguration;
/system/nvram/core/tests/
Dnvram_manager_test.cpp84 ASSERT_TRUE(space.contents.Resize(10)); in TEST_F()
124 ASSERT_TRUE(space.contents.Resize(10)); in TEST_F()
126 ASSERT_TRUE(space.contents.Resize(20)); in TEST_F()
169 ASSERT_TRUE(space.contents.Resize(10)); in TEST_F()
205 ASSERT_TRUE(space.contents.Resize(10)); in TEST_F()
224 ASSERT_TRUE(space.contents.Resize(10)); in TEST_F()
277 ASSERT_TRUE(space.contents.Resize(10)); in TEST_F()
450 ASSERT_TRUE(space.contents.Resize(10)); in TEST_F()
471 ASSERT_TRUE(space.contents.Resize(10)); in TEST_F()
488 ASSERT_TRUE(space.contents.Resize(10)); in TEST_F()
[all …]
/system/tools/aidl/
Dline_reader.cpp63 explicit MemoryLineReader(const string& contents) : input_stream_(contents) {} in MemoryLineReader() argument
94 unique_ptr<LineReader> LineReader::ReadFromMemory(const string& contents) { in ReadFromMemory() argument
95 return unique_ptr<LineReader>(new MemoryLineReader(contents)); in ReadFromMemory()
Dio_delegate.cpp88 unique_ptr<string> contents; in GetFileContents() local
91 return contents; in GetFileContents()
93 contents.reset(new string); in GetFileContents()
96 contents->resize(file_size + content_suffix.length()); in GetFileContents()
99 in.read(&(*contents)[0], file_size); in GetFileContents()
101 contents->replace(file_size, content_suffix.length(), content_suffix); in GetFileContents()
104 return contents; in GetFileContents()
/system/core/adb/fastdeploy/deploypatchgenerator/
Dpatch_utils_test.cpp38 bool FileMatchesContent(android::base::borrowed_fd input, const char* contents, in FileMatchesContent() argument
48 result = memcmp(buffer, contents, readAmount) == 0; in FileMatchesContent()
54 printf("%x", contents[i]); in FileMatchesContent()
86 std::string contents("FASTDEPLOY"); in TEST() local
87 EXPECT_TRUE(FileMatchesContent(output.fd, contents.c_str(), contents.size())); in TEST()
/system/linkerconfig/
DAndroid.bp55 export_include_dirs: [ "contents/include" ],
60 "contents/namespace/*.cc",
61 "contents/section/*.cc",
62 "contents/configuration/*.cc",
63 "contents/context/*.cc",
64 "contents/common/*.cc",
120 "contents/tests/backward_compatibility/*_test.cc",
148 "contents/tests/configuration/include",
151 "contents/tests/configuration/*_test.cc",
Dmain.cc49 using android::linkerconfig::contents::Context;
198 android::linkerconfig::contents::RegisterApexNamespaceBuilders(ctx); in GetContext()
204 return android::linkerconfig::contents::CreateRecoveryConfiguration(ctx); in GetConfiguration()
208 return android::linkerconfig::contents::CreateLegacyConfiguration(ctx); in GetConfiguration()
212 return android::linkerconfig::contents::CreateBaseConfiguration(ctx); in GetConfiguration()
240 android::linkerconfig::contents::CreateRecoveryConfiguration(ctx), in GenerateRecoveryLinkerConfiguration()
246 const std::string& base_dir, android::linkerconfig::contents::Context& ctx, in GenerateApexConfiguration()
254 android::linkerconfig::contents::CreateApexConfiguration(ctx, target_apex), in GenerateApexConfiguration()
/system/linkerconfig/contents/include/linkerconfig/
Dsectionbuilder.h27 android::linkerconfig::contents::Context& ctx);
30 android::linkerconfig::contents::Context& ctx,
35 namespace contents {
Dapexconfig.h24 namespace contents {
26 android::linkerconfig::contents::Context& ctx,
/system/update_engine/common/
Daction_pipe.h61 const ObjectType& contents() const { return contents_; } in contents() function
65 void set_contents(const ObjectType& contents) { contents_ = contents; } in set_contents() argument
/system/linkerconfig/contents/tests/backward_compatibility/
Ddefault_test.cc25 using android::linkerconfig::contents::Context;
39 auto config = android::linkerconfig::contents::CreateBaseConfiguration(ctx); in TEST_F()
95 auto config = android::linkerconfig::contents::CreateBaseConfiguration(ctx); in TEST_F()
120 auto config = android::linkerconfig::contents::CreateBaseConfiguration(ctx); in TEST_F()
135 auto config = android::linkerconfig::contents::CreateBaseConfiguration(ctx); in TEST_F()
Dlegacy_test.cc25 android::linkerconfig::contents::Context ctx; in TEST()
26 auto config = android::linkerconfig::contents::CreateLegacyConfiguration(ctx); in TEST()
/system/core/fs_mgr/libfiemap/
Dutility.cpp112 std::string contents; in F2fsPinBeforeAllocate() local
114 if (!android::base::ReadFileToString(feature_file, &contents)) { in F2fsPinBeforeAllocate()
118 contents = android::base::Trim(contents); in F2fsPinBeforeAllocate()
120 auto features = android::base::Split(contents, ", "); in F2fsPinBeforeAllocate()
/system/core/init/
Dutil_test.cpp82 std::string contents("abcd"); in TEST() local
83 contents.push_back('\0'); in TEST()
84 contents.push_back('\0'); in TEST()
85 contents.append("dcba"); in TEST()
86 ASSERT_EQ(10u, contents.size()); in TEST()
90 EXPECT_RESULT_OK(WriteFile(tf.path, contents)); in TEST()
94 EXPECT_EQ(contents, *read_back_contents); in TEST()
/system/linkerconfig/contents/section/
Dpostinstall.cc28 using android::linkerconfig::contents::SectionType;
34 namespace contents { namespace
/system/nvram/core/
Dnvram_manager.cpp267 if (!space.contents.Resize(request.size)) { in CreateSpace()
271 memset(space.contents.data(), 0, request.size); in CreateSpace()
303 response->size = space_record.persistent.contents.size(); in GetSpaceInfo()
412 Blob& contents = space_record.persistent.contents; in WriteSpace() local
416 if (!sha256_input.Resize(contents.size() + request.buffer.size())) { in WriteSpace()
419 memcpy(sha256_input.data(), contents.data(), contents.size()); in WriteSpace()
420 memcpy(sha256_input.data() + contents.size(), request.buffer.data(), in WriteSpace()
424 crypto::SHA256(sha256_input.data(), sha256_input.size(), contents.data(), in WriteSpace()
425 contents.size()); in WriteSpace()
427 if (contents.size() < request.buffer.size()) { in WriteSpace()
[all …]

123456789