diff -Naur Python-3.8.0-orig/Modules/getpath.c Python-3.8.0/Modules/getpath.c
--- Python-3.8.0-orig/Modules/getpath.c	2019-10-22 10:02:51.821738500 +0300
+++ Python-3.8.0/Modules/getpath.c	2019-10-22 10:05:05.467173300 +0300
@@ -373,7 +373,7 @@
     /* Check for already have an executable suffix */
     size_t n = wcslen(progpath);
     size_t s = wcslen(EXE_SUFFIX);
-    if (wcsncasecmp(EXE_SUFFIX, progpath + n - s, s) == 0) {
+    if (_wcsnicmp(EXE_SUFFIX, progpath + n - s, s) == 0) {
         return _PyStatus_OK();
     }
 
