]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - ncurses/tinfo/access.c
ncurses 6.2 - patch 20210828
[ncurses.git] / ncurses / tinfo / access.c
index 2445e0e0090811cdee6dc032774b195679ab4894..339f169b27bfeed56f1d089daa3d0c6f99a3aa12 100644 (file)
@@ -45,7 +45,7 @@
 
 #include <tic.h>
 
-MODULE_ID("$Id: access.c,v 1.29 2021/06/26 23:50:02 tom Exp $")
+MODULE_ID("$Id: access.c,v 1.30 2021/08/28 22:07:31 tom Exp $")
 
 #define LOWERCASE(c) ((isalpha(UChar(c)) && isupper(UChar(c))) ? tolower(UChar(c)) : (c))
 
@@ -215,7 +215,7 @@ _nc_env_access(void)
 
     if (is_elevated()) {
        result = FALSE;
-    } else if ((getuid() != ROOT_UID) && (geteuid() != ROOT_UID)) {
+    } else if ((getuid() == ROOT_UID) && (geteuid() == ROOT_UID)) {
        result = FALSE;
     }
     return result;