Subject: bug#27986: 26.0.50; 'rename-file' can rename files without confirmation

From: Andy Moreton <[email-masked]>
Date: Tue, 15 Aug 2017 13:45:02 +0100

On Mon 14 Aug 2017, Paul Eggert wrote:

> Paul Eggert wrote:
>> I installed the patch on 'master' to help you do that.
>
> After rereading the Apple manual I installed the attached further patch into
> master, so please try updating to the latest master before testing.

This patch breaks the Windows build for mingw64:

../../src/fileio.c: In function 'Frename_file':
../../src/fileio.c:2300:41: error: duplicate case value
  case EEXIST: case EINVAL: case ENOSYS: case ENOTSUP:
                                         ^~~~
../../src/fileio.c:2300:28: note: previously used here
  case EEXIST: case EINVAL: case ENOSYS: case ENOTSUP:
                            ^~~~

A brief look suggests that the inclusion of ms-w32.h in conf_post.h is
the culprit, as it defines some error numbers before errno.h is
included, and thus overrides the conditional definitions in errno.h.

    AndyM