]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix compilation warnings in the MS-Windows build.
authorEli Zaretskii <eliz@gnu.org>
Tue, 2 Oct 2012 17:55:29 +0000 (19:55 +0200)
committerEli Zaretskii <eliz@gnu.org>
Tue, 2 Oct 2012 17:55:29 +0000 (19:55 +0200)
 src/w32proc.c (sys_wait): Declare 'signame' 'const char *', to be
 consistent with the change in return value of 'safe_strsignal'.

 nt/preprep.c (RVA_TO_PTR): Cast the result to 'void *', to avoid
 compiler warnings when using the value.

nt/ChangeLog
nt/preprep.c
src/ChangeLog
src/w32proc.c

index 42171de032209be532eb7de15fb9c4eadbeb72a7..b0dcb9982f191c678e029e7ff550261d3ab43167 100644 (file)
@@ -1,3 +1,8 @@
+2012-10-02  Eli Zaretskii  <eliz@gnu.org>
+
+       * preprep.c (RVA_TO_PTR): Cast the result to 'void *', to avoid
+       compiler warnings when using the value.
+
 2012-10-01  Eli Zaretskii  <eliz@gnu.org>
 
        * preprep.c (RVA_TO_PTR): Use 'unsigned char *' instead of
index 5a632b3875f5f81a5deb49c17ea6e04f390c2cd7..6976567e038378c028cce528f064758a69632794 100644 (file)
@@ -288,7 +288,7 @@ relocate_offset (DWORD_PTR offset,
   ((DWORD_PTR)(rva) - (section)->VirtualAddress)
 
 #define RVA_TO_PTR(var,section,filedata) \
-  ((unsigned char *)(RVA_TO_OFFSET(var,section) + (filedata)->file_base))
+  ((void *)((unsigned char *)(RVA_TO_OFFSET(var,section) + (filedata)->file_base)))
 
 /* Convert address in executing image to RVA.  */
 #define PTR_TO_RVA(ptr) ((DWORD_PTR)(ptr) - (DWORD_PTR) GetModuleHandle (NULL))
index df4dc76aa07e088cc6444c42a649c3fb9499bf80..1a06b6b5d8435d8629b2c19b7c374cbdf1c453a0 100644 (file)
@@ -1,3 +1,8 @@
+2012-10-02  Eli Zaretskii  <eliz@gnu.org>
+
+       * w32proc.c (sys_wait): Declare 'signame' 'const char *', to be
+       consistent with the change in return value of 'safe_strsignal'.
+
 2012-10-02  Paul Eggert  <eggert@cs.ucla.edu>
 
        Prefer plain 'static' to 'static inline' (Bug#12541).
index 58e6117a7e8842f89967ce1bac0aea5399d2afef..56a60fbf25f09dacd155447907321911642be001 100644 (file)
@@ -1132,7 +1132,7 @@ get_result:
       else if (WIFSIGNALED (retval))
        {
          int code = WTERMSIG (retval);
-         char *signame;
+         const char *signame;
 
          synchronize_system_messages_locale ();
          signame = strsignal (code);