Fix several bugs from cts test through aidl clearkey
* handle error code in DrmHalAidl and CryptoHalAidl
* clearkey aidl getKeyRequest defaultUrl
Test: atest CtsMediaDrmTestCases
Bug: 206804036
Change-Id: I038c6d92df8b222ab69aa48c4b994c8c9516c711
diff --git a/drm/libmediadrm/DrmHalHidl.cpp b/drm/libmediadrm/DrmHalHidl.cpp
index a5dd4d7..c83b52b 100644
--- a/drm/libmediadrm/DrmHalHidl.cpp
+++ b/drm/libmediadrm/DrmHalHidl.cpp
@@ -330,13 +330,14 @@
std::vector<sp<IDrmFactory>> DrmHalHidl::makeDrmFactories() {
static std::vector<sp<IDrmFactory>> factories(DrmUtils::MakeDrmFactories());
if (factories.size() == 0) {
- // must be in passthrough mode, load the default passthrough service
+ DrmUtils::LOG2BI("No hidl drm factories found");
+ // could be in passthrough mode, load the default passthrough service
auto passthrough = IDrmFactory::getService();
if (passthrough != NULL) {
DrmUtils::LOG2BI("makeDrmFactories: using default passthrough drm instance");
factories.push_back(passthrough);
} else {
- DrmUtils::LOG2BE("Failed to find any drm factories");
+ DrmUtils::LOG2BE("Failed to find passthrough drm factories");
}
}
return factories;