< prev index next >

src/java.base/share/classes/sun/nio/ch/IOUtil.java

Print this page
*** 585,13 ***
       * Read and discard at most one byte
       * @return the number of bytes read or IOS_INTERRUPTED
       */
      static native int drain1(int fd) throws IOException;
  
!     public static native void configureBlocking(FileDescriptor fd,
!                                                 boolean blocking)
!         throws IOException;
  
      public static native int fdVal(FileDescriptor fd);
  
      static native void setfdVal(FileDescriptor fd, int value);
  
--- 585,15 ---
       * Read and discard at most one byte
       * @return the number of bytes read or IOS_INTERRUPTED
       */
      static native int drain1(int fd) throws IOException;
  
!     static native void configureBlocking(int fd, boolean blocking) throws IOException;
! 
!     public static void configureBlocking(FileDescriptor fd, boolean blocking) throws IOException {
+         configureBlocking(fdVal(fd), blocking);
+     }
  
      public static native int fdVal(FileDescriptor fd);
  
      static native void setfdVal(FileDescriptor fd, int value);
  
< prev index next >