mirror of
https://github.com/Evolution-X/hardware_interfaces
synced 2026-02-01 16:50:18 +00:00
Merge "Keymint Support: Fix keymint_tags.h"
This commit is contained in:
@@ -326,7 +326,9 @@ template <TagType tag_type, Tag tag>
|
||||
inline std::optional<
|
||||
std::reference_wrapper<const typename TypedTag2ValueType<TypedTag<tag_type, tag>>::type>>
|
||||
authorizationValue(TypedTag<tag_type, tag> ttag, const KeyParameter& param) {
|
||||
if (TypedTag2ValueType<TypedTag<tag_type, tag>>::unionTag != param.value.getTag()) return {};
|
||||
// We only check if the parameter has the correct tag here; accessTagValue checks if the correct
|
||||
// union field was initialized.
|
||||
if (tag != param.tag) return {};
|
||||
return accessTagValue(ttag, param);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user