Make dynamic partition control android return a writable fd
We can return a FileDescriptor object, which encapsulates logic needed
to write to a COW. This way, filesystem verfication action can use the
turend value directly for computing verity and hash the partition.
Test: th
Change-Id: Iafe9699ef0cc15961641fc94f8ad2820230a56e1
diff --git a/common/dynamic_partition_control_stub.h b/common/dynamic_partition_control_stub.h
index eb7154c..515ec7c 100644
--- a/common/dynamic_partition_control_stub.h
+++ b/common/dynamic_partition_control_stub.h
@@ -64,9 +64,12 @@
const std::string& unsuffixed_partition_name,
const std::optional<std::string>&,
bool is_append) override;
- FileDescriptorPtr OpenCowReader(const std::string& unsuffixed_partition_name,
- const std::optional<std::string>&,
- bool is_append = false) override;
+
+ FileDescriptorPtr OpenCowFd(const std::string& unsuffixed_partition_name,
+ const std::optional<std::string>&,
+ bool is_append = false) override {
+ return nullptr;
+ }
bool MapAllPartitions() override;
bool UnmapAllPartitions() override;