diff options
author | Yifan Hong | 2018-06-29 13:32:57 -0500 |
---|---|---|
committer | Yifan Hong | 2018-06-29 13:40:30 -0500 |
commit | 0a35ab16fe5cca240b83a60575133d1b39d862fc (patch) | |
tree | ce25f65405804281cfe39296370b2da4a1ec25a6 /include | |
parent | 13ebc4c20d11fda557205dc13e489320f8c8c774 (diff) | |
download | platform-system-libvintf-0a35ab16fe5cca240b83a60575133d1b39d862fc.tar.gz platform-system-libvintf-0a35ab16fe5cca240b83a60575133d1b39d862fc.tar.xz platform-system-libvintf-0a35ab16fe5cca240b83a60575133d1b39d862fc.zip |
assemble_vintf: first arg cannot contain extra things
... other than <hal> and type attribute.
Bug: 78943004
Test: build vintf stuff
Test: add extra device manifest and the following fails:
- specify "level"
- specify <sepolicy>
Change-Id: I1b0bbae5727dc8a0de1ff043ccf126d9e7c65e9b
Diffstat (limited to 'include')
-rw-r--r-- | include/vintf/HalGroup.h | 1 | ||||
-rw-r--r-- | include/vintf/HalManifest.h | 3 |
2 files changed, 4 insertions, 0 deletions
diff --git a/include/vintf/HalGroup.h b/include/vintf/HalGroup.h index 74be9af..a0a14cd 100644 --- a/include/vintf/HalGroup.h +++ b/include/vintf/HalGroup.h | |||
@@ -44,6 +44,7 @@ struct HalGroup { | |||
44 | return false; | 44 | return false; |
45 | } | 45 | } |
46 | } | 46 | } |
47 | other->mHals.clear(); | ||
47 | return true; | 48 | return true; |
48 | } | 49 | } |
49 | 50 | ||
diff --git a/include/vintf/HalManifest.h b/include/vintf/HalManifest.h index c8d4872..b72c1b2 100644 --- a/include/vintf/HalManifest.h +++ b/include/vintf/HalManifest.h | |||
@@ -159,6 +159,9 @@ struct HalManifest : public HalGroup<ManifestHal>, public XmlFileGroup<ManifestX | |||
159 | // (instance in manifest) => (instance in matrix). | 159 | // (instance in manifest) => (instance in matrix). |
160 | std::set<std::string> checkUnusedHals(const CompatibilityMatrix& mat) const; | 160 | std::set<std::string> checkUnusedHals(const CompatibilityMatrix& mat) const; |
161 | 161 | ||
162 | // Check that manifest has no entries. | ||
163 | bool empty() const; | ||
164 | |||
162 | SchemaType mType; | 165 | SchemaType mType; |
163 | Level mLevel = Level::UNSPECIFIED; | 166 | Level mLevel = Level::UNSPECIFIED; |
164 | // version attribute. Default is 1.0 for manifests created programatically. | 167 | // version attribute. Default is 1.0 for manifests created programatically. |