public synchronized void release(){
  if (lock != null) {
    try {
      lock.release();
    }
 catch (    IOException e) {
    }
    lock=null;
    close(raf);
    raf=null;
  }
}

public synchronized void release ( ) { if ( lock != null ) { try { lock . release ( ) ; } catch ( IOException e ) { } lock = null ; close ( raf ) ; raf = null ; } }
release the write lock . this call is idempotent .
