title: "rd" exits with errorlevel set to 0 on error when deletion fails, etc
body: <p>I'm writing a batch (.bat) script and I need to handle the case in which the deletion of a folder fails. I'm using <code>%errorlevel%</code> to catch the exit code, but in the case of the <code>rd</code> command it seems not to work:</p>
  
  <pre><code>C:\Users\edo\Desktop&gt;rd testdir
  Directory is not empty
  
  C:\Users\edo\Desktop&gt;echo %errorlevel%
  0
  </code></pre>
  
  <p>Why? What do you suggest?</p>