[Replicant] [PATCH 5/7] Fix checking of access() return value in EGL renderer override

Andrés Domínguez andresdju at gmail.com
Thu Aug 15 19:04:31 UTC 2019


From: JeremyRand <biolizard89 at gmail.com>

---
 opengl/libs/EGL/Loader.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/opengl/libs/EGL/Loader.cpp b/opengl/libs/EGL/Loader.cpp
index 0712031ae..b90c49166 100644
--- a/opengl/libs/EGL/Loader.cpp
+++ b/opengl/libs/EGL/Loader.cpp
@@ -157,7 +157,7 @@ static const char* getOverridePath(void) {
     ALOGD("checking %s for override...",
         data_override_path.string());
 
-    if (access( data_override_path.string(), R_OK ) ) {
+    if (!access( data_override_path.string(), R_OK ) ) {
         ALOGD("override found: %s", data_override_path.string());
 	return data_override_path.string();
     }
@@ -169,7 +169,7 @@ static const char* getOverridePath(void) {
     ALOGD("checking %s for override...",
         system_override_path.string());
 
-    if (access( system_override_path.string(), R_OK ) ) {
+    if (!access( system_override_path.string(), R_OK ) ) {
         ALOGD("override found: %s", system_override_path.string());
 	return system_override_path.string();
     }
-- 
2.23.0.rc1



More information about the Replicant mailing list