mingw_rmdir: set errno=ENOTEMPTY when appropriate
commitd3bc6e71de350f9dd39f54eceb99702beb5ed199
authorJohannes Schindelin <johannes.schindelin@gmx.de>
Wed, 26 May 2010 10:42:50 +0000 (26 12:42 +0200)
committerJohannes Schindelin <johannes.schindelin@gmx.de>
Sun, 19 Dec 2010 22:13:49 +0000 (19 23:13 +0100)
treefdbbe43a04a48b2dad99d2a8636d7fcf116210da
parentbcfc9ba39674c6ec62e6bc5032c4f9c7de9c76cc
mingw_rmdir: set errno=ENOTEMPTY when appropriate

On Windows, EACCES overrules ENOTEMPTY when calling rmdir(). But if the
directory is busy, we only want to retry deleting the directory if it
is empty, so test specifically for that case and set ENOTEMPTY rather
than EACCES.

Noticed by Greg Hazel.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
compat/mingw.c