< prev index next >

src/java.base/windows/native/libjli/java_md.c

Print this page

        

@@ -502,11 +502,11 @@
 
     /*
      * Get required buffer size to convert to Unicode.
      * The return value includes the terminating null character.
      */
-    unicode_path_len = MultiByteToWideChar(CP_THREAD_ACP, MB_ERR_INVALID_CHARS,
+    unicode_path_len = MultiByteToWideChar(CP_ACP, MB_ERR_INVALID_CHARS,
                                            path, -1, NULL, 0);
     if (unicode_path_len == 0) {
         return EINVAL;
     }
 

@@ -516,11 +516,11 @@
     if (*wpath == NULL) {
         return ENOMEM;
     }
 
     wcsncpy(*wpath, prefix, prefix_len);
-    if (MultiByteToWideChar(CP_THREAD_ACP, MB_ERR_INVALID_CHARS,
+    if (MultiByteToWideChar(CP_ACP, MB_ERR_INVALID_CHARS,
                             path, -1, &((*wpath)[prefix_len]), (int)wpath_len) == 0) {
         JLI_MemFree(*wpath);
         *wpath = NULL;
         return EINVAL;
     }
< prev index next >