chore: fix compile errors (#30903)
This commit is contained in:
parent
57d088517c
commit
fb539f15d0
5 changed files with 25 additions and 11 deletions
|
@ -157,6 +157,15 @@ bool FillFileInfoWithNode(Archive::FileInfo* info,
|
|||
|
||||
} // namespace
|
||||
|
||||
IntegrityPayload::IntegrityPayload()
|
||||
: algorithm(HashAlgorithm::NONE), block_size(0) {}
|
||||
IntegrityPayload::~IntegrityPayload() = default;
|
||||
IntegrityPayload::IntegrityPayload(const IntegrityPayload& other) = default;
|
||||
|
||||
Archive::FileInfo::FileInfo()
|
||||
: unpacked(false), executable(false), size(0), offset(0) {}
|
||||
Archive::FileInfo::~FileInfo() = default;
|
||||
|
||||
Archive::Archive(const base::FilePath& path)
|
||||
: initialized_(false), path_(path), file_(base::File::FILE_OK) {
|
||||
base::ThreadRestrictions::ScopedAllowIO allow_io;
|
||||
|
@ -270,11 +279,11 @@ bool Archive::Init() {
|
|||
|
||||
#if !defined(OS_MAC)
|
||||
absl::optional<IntegrityPayload> Archive::HeaderIntegrity() const {
|
||||
return absl::optional<IntegrityPayload>();
|
||||
return absl::nullopt;
|
||||
}
|
||||
|
||||
absl::optional<base::FilePath> Archive::RelativePath() const {
|
||||
return absl::optional<base::FilePath>();
|
||||
return absl::nullopt;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
@ -29,7 +29,9 @@ enum HashAlgorithm {
|
|||
};
|
||||
|
||||
struct IntegrityPayload {
|
||||
IntegrityPayload() : algorithm(HashAlgorithm::NONE), block_size(0) {}
|
||||
IntegrityPayload();
|
||||
~IntegrityPayload();
|
||||
IntegrityPayload(const IntegrityPayload& other);
|
||||
HashAlgorithm algorithm;
|
||||
std::string hash;
|
||||
uint32_t block_size;
|
||||
|
@ -41,7 +43,8 @@ struct IntegrityPayload {
|
|||
class Archive {
|
||||
public:
|
||||
struct FileInfo {
|
||||
FileInfo() : unpacked(false), executable(false), size(0), offset(0) {}
|
||||
FileInfo();
|
||||
~FileInfo();
|
||||
bool unpacked;
|
||||
bool executable;
|
||||
uint32_t size;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue