title: "IOException: There is not enough space on the disk." while there is enough space
body: <p>I made sequence of operations (on local disk):</p>
  
  <ol>
  <li>Copy file to ###.bak </li>
  <li>Save file to ### </li>
  <li>Delete file ###.bak</li>
  </ol>
  
  <p>Code:</p>
  
  <pre><code>File.Copy(filename, filename + ".bak");
  TextWriter writer = new StreamWriter(filename);
  writer.Write(content);
  writer.Close();
  File.Delete(filename + ".bak");
  </code></pre>
  
  <p>During deleting I got exception:</p>
  
  <pre><code>IOException: There is not enough space on the disk.
  at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
  at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite)
  </code></pre>
  
  <p>Size of both files is maximum few MB. And I checked - there is enough free space on disk (more than few GBs). 
  What are possible reasons for that situations?</p>
  
  <p>It's a desktop app (WPF), running on OS drive, on admin account. </p>