mirror of
https://github.com/openjdk/jdk.git
synced 2026-04-07 05:28:52 +00:00
8261939: os::strdup_check_oom() should be used in os::same_files() in os_windows.cpp
Reviewed-by: minqi
This commit is contained in:
parent
5f308291a0
commit
b8fd61420c
@ -4481,9 +4481,9 @@ bool os::same_files(const char* file1, const char* file2) {
|
||||
return true;
|
||||
}
|
||||
|
||||
char* native_file1 = os::strdup(file1);
|
||||
char* native_file1 = os::strdup_check_oom(file1);
|
||||
native_file1 = os::native_path(native_file1);
|
||||
char* native_file2 = os::strdup(file2);
|
||||
char* native_file2 = os::strdup_check_oom(file2);
|
||||
native_file2 = os::native_path(native_file2);
|
||||
if (strcmp(native_file1, native_file2) == 0) {
|
||||
os::free(native_file1);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user