bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#28097: 26.0.50; Commit 9746058 breaks build on MS-Windows


From: Chris Zheng
Subject: bug#28097: 26.0.50; Commit 9746058 breaks build on MS-Windows
Date: Tue, 15 Aug 2017 22:45:06 +0800
User-agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM/1.14.9 (Gojō) APEL/10.8 EasyPG/1.0.0 Emacs/26.0 (x86_64-w64-mingw32) MULE/6.0 (HANACHIRUSATO)

The error message is

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

Because the file nt/inc/ms-w32.h, line 389, has the definition
“#define ENOTSUP ENOSYS” and it is included early than errno.h
which has the right define. One possible fix is is

@@ -2297,7 +2297,10 @@ This is what happens in interactive use with M-x.  */)
       rename_errno = errno;
       switch (rename_errno)
        {
-       case EEXIST: case EINVAL: case ENOSYS: case ENOTSUP:
+       case EEXIST: case EINVAL: case ENOSYS:
+#ifdef DARWIN_OS
+       case ENOTSUP:
+#endif
          barf_or_query_if_file_exists (newname, rename_errno == EEXIST,
                                        "rename to it",
                                        INTEGERP (ok_if_already_exists),

Or we can change the #define in ms-w32.h.

Could you please have a look on it?

Thank you,
Chris






reply via email to

[Prev in Thread] Current Thread [Next in Thread]