/bootable/recovery/tests/unit/ |
D | dirutil_test.cpp | 58 struct stat sb; in TEST() local 59 ASSERT_EQ(0, stat(path.c_str(), &sb)) << strerror(errno); in TEST() 60 ASSERT_TRUE(S_ISDIR(sb.st_mode)); in TEST() 62 ASSERT_EQ(mode, sb.st_mode & mask); in TEST() 76 struct stat sb; in TEST() local 77 ASSERT_EQ(0, stat((prefix + "/a").c_str(), &sb)) << strerror(errno); in TEST() 78 ASSERT_TRUE(S_ISDIR(sb.st_mode)); in TEST() 80 ASSERT_EQ(-1, stat(path.c_str(), &sb)); in TEST() 95 struct stat sb; in TEST() local 96 ASSERT_EQ(0, stat(path.c_str(), &sb)) << strerror(errno); in TEST() [all …]
|
D | fuse_sideload_test.cpp | 89 struct stat sb; in TEST() local 90 if (stat(package.c_str(), &sb) == 0) { in TEST() 106 struct stat sb; in TEST() local 107 ASSERT_EQ(0, stat(exit_flag.c_str(), &sb)); in TEST()
|
D | install_test.cpp | 133 struct stat sb; in TEST() local 134 ASSERT_EQ(0, stat(binary_path.c_str(), &sb)); in TEST() 135 ASSERT_EQ(static_cast<mode_t>(0755), sb.st_mode & (S_IRWXU | S_IRWXG | S_IRWXO)); in TEST() 146 sb = {}; in TEST() 147 ASSERT_EQ(0, stat(binary_path.c_str(), &sb)); in TEST() 148 ASSERT_EQ(static_cast<mode_t>(0755), sb.st_mode & (S_IRWXU | S_IRWXG | S_IRWXO)); in TEST()
|
/bootable/recovery/uncrypt/ |
D | uncrypt.cpp | 263 struct stat sb; in ProductBlockMap() local 264 if (stat(path.c_str(), &sb) != 0) { in ProductBlockMap() 269 LOG(INFO) << " block size: " << sb.st_blksize << " bytes"; in ProductBlockMap() 271 int blocks = ((sb.st_size - 1) / sb.st_blksize) + 1; in ProductBlockMap() 272 LOG(INFO) << " file size: " << sb.st_size << " bytes, " << blocks << " blocks"; in ProductBlockMap() 277 static_cast<int64_t>(sb.st_size), in ProductBlockMap() 278 static_cast<int64_t>(sb.st_blksize)); in ProductBlockMap() 286 buffers.resize(WINDOW_SIZE, std::vector<unsigned char>(sb.st_blksize)); in ProductBlockMap() 334 while (pos < sb.st_size) { in ProductBlockMap() 336 int progress = static_cast<int>(100 * (double(pos) / double(sb.st_size))); in ProductBlockMap() [all …]
|
/bootable/recovery/minadbd/ |
D | minadbd_services_test.cpp | 79 struct stat sb; in WaitForFusePath() local 80 if (stat(package_path_.c_str(), &sb) == 0) { in WaitForFusePath() 93 struct stat sb; in StatExitFlagAndExitProcess() local 94 if (stat(exit_flag_.c_str(), &sb) != 0) { in StatExitFlagAndExitProcess() 152 struct stat sb; in TEST_F() local 153 ASSERT_EQ(0, stat(exit_flag_.c_str(), &sb)); in TEST_F()
|
/bootable/recovery/otautil/ |
D | sysutil.cpp | 106 struct stat sb; in MapFD() local 107 if (fstat(fd, &sb) == -1) { in MapFD() 112 void* memPtr = mmap(nullptr, sb.st_size, PROT_READ, MAP_PRIVATE, fd, 0); in MapFD() 114 PLOG(ERROR) << "mmap(" << sb.st_size << ", R, PRIVATE, " << fd << ", 0) failed"; in MapFD() 119 length = sb.st_size; in MapFD() 121 ranges_.emplace_back(MappedRange{ memPtr, static_cast<size_t>(sb.st_size) }); in MapFD()
|
D | dirutil.cpp | 34 struct stat sb; in dir_status() local 35 if (stat(path.c_str(), &sb) == 0) { in dir_status() 37 if (S_ISDIR(sb.st_mode)) { in dir_status()
|
/bootable/recovery/recovery_utils/ |
D | logging.cpp | 276 struct stat sb; in ReadLogFilesToMemory() local 277 if (stat(path.c_str(), &sb) != 0) { in ReadLogFilesToMemory() 282 size_t read_size = std::min<size_t>(sb.st_size, 1 << 19); in ReadLogFilesToMemory() 291 log_files.emplace_back(saved_log_file{ path, sb, data }); in ReadLogFilesToMemory() 311 if (!android::base::WriteStringToFile(log.data, log.name, log.sb.st_mode, log.sb.st_uid, in RestoreLogFilesAfterFormat() 312 log.sb.st_gid)) { in RestoreLogFilesAfterFormat()
|
/bootable/recovery/install/ |
D | fuse_install.cpp | 172 struct stat sb; in InstallWithFuseFromPath() local 173 if (stat(FUSE_SIDELOAD_HOST_PATHNAME, &sb) == -1) { in InstallWithFuseFromPath() 195 struct stat sb; in InstallWithFuseFromPath() local 196 stat(FUSE_SIDELOAD_HOST_EXIT_PATHNAME, &sb); in InstallWithFuseFromPath()
|
/bootable/recovery/fuse_sideload/ |
D | fuse_provider.cpp | 37 struct stat sb; in FuseFileDataProvider() local 38 if (stat(path.c_str(), &sb) == -1) { in FuseFileDataProvider() 48 file_size_ = sb.st_size; in FuseFileDataProvider()
|
/bootable/recovery/updater/ |
D | blockimg.cpp | 761 struct stat sb; in LoadStash() local 762 if (stat(fn.c_str(), &sb) == -1) { in LoadStash() 772 if ((sb.st_size % BLOCKSIZE) != 0) { in LoadStash() 773 LOG(ERROR) << fn << " size " << sb.st_size << " not multiple of block size " << BLOCKSIZE; in LoadStash() 784 allocate(sb.st_size, buffer); in LoadStash() 786 if (!android::base::ReadFully(fd, buffer->data(), sb.st_size)) { in LoadStash() 788 PLOG(ERROR) << "Failed to read " << sb.st_size << " bytes of data"; in LoadStash() 792 size_t blocks = sb.st_size / BLOCKSIZE; in LoadStash() 824 struct stat sb; in WriteStash() local 825 int res = stat(cn.c_str(), &sb); in WriteStash() [all …]
|
D | dynamic_partitions.cpp | 107 struct stat sb; in UpdateDynamicPartitionsFn() local 108 int result = stat(updated_marker.c_str(), &sb); in UpdateDynamicPartitionsFn()
|
/bootable/recovery/recovery_utils/include/recovery_utils/ |
D | logging.h | 35 struct stat sb; member
|
/bootable/recovery/recovery_ui/ |
D | screen_ui.cpp | 1120 struct stat sb; in ShowFile() local 1121 fstat(fileno(fp), &sb); in ShowFile() 1127 static_cast<int>(100 * (double(ftello(fp)) / double(sb.st_size))), in ShowFile() 1128 static_cast<int>(sb.st_size)); in ShowFile()
|
/bootable/recovery/tests/testdata/ |
D | recovery_body | 3048 ������c-�Ls��lTMՖ�by�����>sb��.�_ep��Me�J�$�l��#�&�b 4Q�F�o��[嶺eSM7��f?��0�Lrw��~�… 4054 Z�zH�DT�i��b8]�[\t;��)�"|����Y�v/�dV��+���9���{��)o,)|{O��'�a�~��Ps�,!��sb���Y�+��u�A…
|