title: How can closing a FileInputStream cause a "No Space Left on Device" error?
body: <p>I am a bit confused with an error my program started throwing recently.</p>
  
  <pre><code>java.io.IOException: No space left on device
      at java.io.FileInputStream.close0(Native Method)
      at java.io.FileInputStream.close(FileInputStream.java:259)
      at java.io.FilterInputStream.close(FilterInputStream.java:155)
  </code></pre>
  
  <p>I am assuming that since this is a FileInputStream, that this file is being held in memory, and not on the physical disk. Memory levels look great, and as does disk space. This is especially confusing since it happens on the close of the FileInputStream. Thanks for any explanations you might have as to how this can occur.</p>
  
  <p>EDIT: Code for review</p>
  
  <pre><code>if (this.file.exists()) {
              DataInputStream is = new DataInputStream(new FileInputStream(this.file));
              this.startDate = new DateTime(is.readLong(), this.timeZone);
              this.endDate = new DateTime(is.readLong(), this.timeZone);
              is.close();
          } 
  </code></pre>
  
  <p>As you can see above I am only opening the file, reading some content, and then closing the file.</p>