Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f6a64588 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Revert "Revert "Do not allow wildcard matching in GL loader.""" into...

Merge "Revert "Revert "Do not allow wildcard matching in GL loader.""" into udc-qpr-dev am: 3a135c3c am: b63a665b

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/native/+/23415349



Change-Id: Ibcdb796cfcb0aeabc2cfadd0efc3c3459953e223
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 8be3df18 b63a665b
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -21,6 +21,7 @@

#include <android-base/properties.h>
#include <android/dlext.h>
#include <cutils/properties.h>
#include <dirent.h>
#include <dlfcn.h>
#include <graphicsenv/GraphicsEnv.h>
@@ -261,7 +262,10 @@ void* Loader::open(egl_connection_t* cnx)
        hnd = attempt_to_load_system_driver(cnx, nullptr, true);
    }

    if (!hnd && !failToLoadFromDriverSuffixProperty) {
    if (!hnd && !failToLoadFromDriverSuffixProperty &&
        property_get_int32("ro.vendor.api_level", 0) < __ANDROID_API_U__) {
        // Still can't find the graphics drivers with the exact name. This time try to use wildcard
        // matching if the device is launched before Android 14.
        hnd = attempt_to_load_system_driver(cnx, nullptr, false);
    }