Revert "Reland "Remove gBn/sConstructorMap.""
This reverts commit d7687b2a89d374d8403b4c6c7f94a21c747aa66f.
Reason for revert: b/73103210
Change-Id: Ibd956944c49f4b1a2e51992a4d199a60cd64d7b5
diff --git a/transport/HidlPassthroughSupport.cpp b/transport/HidlPassthroughSupport.cpp
index d7903bd..e5eb164 100644
--- a/transport/HidlPassthroughSupport.cpp
+++ b/transport/HidlPassthroughSupport.cpp
@@ -27,6 +27,9 @@
static sp<IBase> tryWrap(const std::string& descriptor, sp<IBase> iface) {
auto func = getBsConstructorMap().get(descriptor, nullptr);
+ if (!func) {
+ func = gBsConstructorMap.get(descriptor, nullptr);
+ }
if (func) {
return func(static_cast<void*>(iface.get()));
}