Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c768ffe

Browse files
committed
Fixed call to MapViewOfFile to use size_t cast
1 parent 598607d commit c768ffe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

larray-mmap/src/main/java/xerial/larray/impl/LArrayNative.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ JNIEXPORT jlong JNICALL Java_xerial_larray_impl_LArrayNative_mmap
6767
}
6868

6969
mapping = CreateFileMapping(fileHandle, NULL, fileProtect, highLen, lowLen, NULL);
70-
mapAddress = MapViewOfFile(mapping, mapAccess, highOffset, lowOffset, (DWORD) size);
70+
mapAddress = MapViewOfFile(mapping, mapAccess, highOffset, lowOffset, (size_t) size);
7171

7272
result = CloseHandle(mapping);
7373
return (jlong) mapAddress;

0 commit comments

Comments
 (0)