# HG changeset patch # User martin # Date 1205184771 25200 # Node ID 307f564057c10fa7a67aeb45513374173c7ee0cb # Parent 9291315d799d2ee52b05d0e4f85df6d6486d780d 6631362: Nuke io_util_md.c:handleFileSizeFD (win) Reviewed-by: alanb, iris diff -r 9291315d799d -r 307f564057c1 jdk/src/windows/native/java/io/io_util_md.c --- a/jdk/src/windows/native/java/io/io_util_md.c Mon Mar 10 14:32:51 2008 -0700 +++ b/jdk/src/windows/native/java/io/io_util_md.c Mon Mar 10 14:32:51 2008 -0700 @@ -444,24 +444,6 @@ return 0; } -int -handleFileSizeFD(jlong fd, jlong *size) -{ - DWORD sizeLow = 0; - DWORD sizeHigh = 0; - HANDLE h = (HANDLE)fd; - if (h == INVALID_HANDLE_VALUE) { - return -1; - } - sizeLow = GetFileSize(h, &sizeHigh); - if (sizeLow == ((DWORD)-1)) { - if (GetLastError() != ERROR_SUCCESS) { - return -1; - } - } - return (((jlong)sizeHigh) << 32) | sizeLow; -} - JNIEXPORT size_t handleRead(jlong fd, void *buf, jint len) diff -r 9291315d799d -r 307f564057c1 jdk/src/windows/native/java/io/io_util_md.h --- a/jdk/src/windows/native/java/io/io_util_md.h Mon Mar 10 14:32:51 2008 -0700 +++ b/jdk/src/windows/native/java/io/io_util_md.h Mon Mar 10 14:32:51 2008 -0700 @@ -38,7 +38,6 @@ int handleAvailable(jlong fd, jlong *pbytes); JNIEXPORT int handleSync(jlong fd); int handleSetLength(jlong fd, jlong length); -int handleFileSizeFD(jlong fd, jlong *size); JNIEXPORT size_t handleRead(jlong fd, void *buf, jint len); JNIEXPORT size_t handleWrite(jlong fd, const void *buf, jint len); jint handleClose(JNIEnv *env, jobject this, jfieldID fid);