Lines Matching refs:sb
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()
884 struct stat sb; in CreateStash() local
885 int res = stat(dirname.c_str(), &sb); in CreateStash()
931 struct stat sb; in CreateStash() local
932 if (stat(fn.c_str(), &sb) == -1) { in CreateStash()
936 existing += static_cast<size_t>(sb.st_size); in CreateStash()
1446 struct stat sb; in PerformCommandErase() local
1447 if (fstat(params.fd, &sb) == -1) { in PerformCommandErase()
1452 if (!S_ISBLK(sb.st_mode)) { in PerformCommandErase()
1593 struct stat sb; in Sha1DevicePath() local
1594 if (stat(dm_target_name_path.c_str(), &sb) == 0) { in Sha1DevicePath()
1722 struct stat sb; in PerformBlockImageUpdate() local
1723 int result = stat(updated_marker.c_str(), &sb); in PerformBlockImageUpdate()