mirror of
https://github.com/corda/corda.git
synced 2025-01-05 20:54:13 +00:00
fix memory leak in Java_java_io_File_lastModified (exposed in debug mode)
This commit is contained in:
parent
526e3a41a8
commit
b3d4f33522
@ -584,8 +584,10 @@ Java_java_io_File_lastModified(JNIEnv* e, jclass, jstring path)
|
||||
return fileDate.QuadPart / 10000000L;
|
||||
#else
|
||||
struct stat fileStat;
|
||||
if (stat(chars, &fileStat) == -1) {
|
||||
int res = stat(chars, &fileStat);
|
||||
releaseChars(e, path, chars);
|
||||
|
||||
if (res == -1) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user