apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From traw...@apache.org
Subject svn commit: r1707717 - in /apr/apr/branches/1.5.x/include: apr.hw apr.hwc
Date Fri, 09 Oct 2015 13:05:20 GMT
Author: trawick
Date: Fri Oct  9 13:05:19 2015
New Revision: 1707717

URL: http://svn.apache.org/viewvc?rev=1707717&view=rev
Log:
Merge r1707712 from 1.6.x branch:

modest apr.h improvements for Windows, from various trunk commits

* Ignore certain warnings with MSVC.
* Align whitespace and improve some comments
* Conditionally include additional header files as on Unix (none of these
  will be included without modifying defines)

(The APR_HAVE_SOCKADDR_UN change to apr.hwc is not appropriate for this
branch.)

PR: this is tiny help for 58476

Modified:
    apr/apr/branches/1.5.x/include/apr.hw
    apr/apr/branches/1.5.x/include/apr.hwc

Modified: apr/apr/branches/1.5.x/include/apr.hw
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.5.x/include/apr.hw?rev=1707717&r1=1707716&r2=1707717&view=diff
==============================================================================
--- apr/apr/branches/1.5.x/include/apr.hw (original)
+++ apr/apr/branches/1.5.x/include/apr.hw Fri Oct  9 13:05:19 2015
@@ -25,7 +25,7 @@
  * And please, make an effort to stub apr.hnw and apr.h.in in the process.
  *
  * This is the Win32 specific version of apr.h.  It is copied from
- * apr.hw by the apr.dsp and libapr.dsp projects. 
+ * apr.hw by the apr.dsp and libapr.dsp projects.
  */
 
 /**
@@ -60,7 +60,9 @@
  *   C4244: int to char/short - precision loss
  *   C4514: unreferenced inline function removed
  */
+#if defined(_MSC_VER)
 #pragma warning(disable: 4100 4127 4163 4201 4514; once: 4057 4075 4244)
+#endif
 
 /* Ignore Microsoft's interpretation of secure development
  * and the POSIX string handling API
@@ -212,25 +214,42 @@
 /** @} */
 /** @} */
 
-/* We don't include our conditional headers within the doxyblocks 
- * or the extern "C" namespace 
+/* We don't include our conditional headers within the doxyblocks
+ * or the extern "C" namespace
  */
 
 #if APR_HAVE_STDLIB_H
 #include <stdlib.h>
 #endif
+
 #if APR_HAVE_STDIO_H
 #include <stdio.h>
 #endif
+
 #if APR_HAVE_SYS_TYPES_H
 #include <sys/types.h>
 #endif
+
 #if APR_HAVE_STDDEF_H
 #include <stddef.h>
 #endif
+
+#if APR_HAVE_SYS_SOCKET_H
+#include <sys/socket.h>
+#endif
+
+#if APR_HAVE_STDINT_H
+#include <stdint.h>
+#endif
+
+#if APR_HAVE_SYS_WAIT_H
+#include <sys/wait.h>
+#endif
+
 #if APR_HAVE_TIME_H
 #include <time.h>
 #endif
+
 #if APR_HAVE_PROCESS_H
 #include <process.h>
 #endif
@@ -261,12 +280,12 @@ extern "C" {
 #define APR_USE_SHMEM_MMAP_ANON    0
 #define APR_USE_SHMEM_BEOS         0
 
-#define APR_USE_FLOCK_SERIALIZE           0 
+#define APR_USE_FLOCK_SERIALIZE           0
 #define APR_USE_POSIXSEM_SERIALIZE        0
 #define APR_USE_SYSVSEM_SERIALIZE         0
 #define APR_USE_FCNTL_SERIALIZE           0
-#define APR_USE_PROC_PTHREAD_SERIALIZE    0 
-#define APR_USE_PTHREAD_SERIALIZE         0 
+#define APR_USE_PROC_PTHREAD_SERIALIZE    0
+#define APR_USE_PTHREAD_SERIALIZE         0
 
 #define APR_HAS_FLOCK_SERIALIZE           0
 #define APR_HAS_SYSVSEM_SERIALIZE         0
@@ -354,7 +373,7 @@ extern "C" {
 
 /* Is the O_NONBLOCK flag inherited from listening sockets?
  */
-#define APR_O_NONBLOCK_INHERITED  1
+#define APR_O_NONBLOCK_INHERITED 1
 
 /* Typedefs that APR needs. */
 
@@ -626,18 +645,20 @@ typedef  int         gid_t;
      && (*(const apr_uint32_t *)(const void *)(&(a)->s6_addr[8]) == ntohl(0x0000ffff)))
 #endif
 
-#endif /* APR_HAS_IPV6 */
+#endif /* APR_HAVE_IPV6 */
 
 #ifdef __cplusplus
 }
 #endif
 
-/* Done with badly written headers
+/* Done with badly written headers, leave 'deprecated CRT' undeprecated
  */
 #if defined(_MSC_VER) && _MSC_VER >= 1200
 #pragma warning(pop)
+#if _MSC_VER >= 1400
 #pragma warning(disable: 4996)
 #endif
+#endif
 
 #endif /* WIN32 */
 

Modified: apr/apr/branches/1.5.x/include/apr.hwc
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.5.x/include/apr.hwc?rev=1707717&r1=1707716&r2=1707717&view=diff
==============================================================================
--- apr/apr/branches/1.5.x/include/apr.hwc (original)
+++ apr/apr/branches/1.5.x/include/apr.hwc Fri Oct  9 13:05:19 2015
@@ -25,7 +25,7 @@
  * And please, make an effort to stub apr.hnw and apr.h.in in the process.
  *
  * This is the Win32 specific version of apr.h.  It is copied from
- * apr.hw by the apr.dsp and libapr.dsp projects. 
+ * apr.hw by the apr.dsp and libapr.dsp projects.
  */
 
 /**
@@ -60,7 +60,9 @@
  *   C4244: int to char/short - precision loss
  *   C4514: unreferenced inline function removed
  */
+#if defined(_MSC_VER)
 #pragma warning(disable: 4100 4127 4163 4201 4514; once: 4057 4075 4244)
+#endif
 
 /* Ignore Microsoft's interpretation of secure development
  * and the POSIX string handling API
@@ -209,25 +211,42 @@
 /** @} */
 /** @} */
 
-/* We don't include our conditional headers within the doxyblocks 
- * or the extern "C" namespace 
+/* We don't include our conditional headers within the doxyblocks
+ * or the extern "C" namespace
  */
 
 #if APR_HAVE_STDLIB_H
 #include <stdlib.h>
 #endif
+
 #if APR_HAVE_STDIO_H
 #include <stdio.h>
 #endif
+
 #if APR_HAVE_SYS_TYPES_H
 #include <sys/types.h>
 #endif
+
 #if APR_HAVE_STDDEF_H
 #include <stddef.h>
 #endif
+
+#if APR_HAVE_SYS_SOCKET_H
+#include <sys/socket.h>
+#endif
+
+#if APR_HAVE_STDINT_H
+#include <stdint.h>
+#endif
+
+#if APR_HAVE_SYS_WAIT_H
+#include <sys/wait.h>
+#endif
+
 #if APR_HAVE_TIME_H
 #include <time.h>
 #endif
+
 #if APR_HAVE_PROCESS_H
 #include <process.h>
 #endif
@@ -258,12 +277,12 @@ extern "C" {
 #define APR_USE_SHMEM_MMAP_ANON    0
 #define APR_USE_SHMEM_BEOS         0
 
-#define APR_USE_FLOCK_SERIALIZE           0 
+#define APR_USE_FLOCK_SERIALIZE           0
 #define APR_USE_POSIXSEM_SERIALIZE        0
 #define APR_USE_SYSVSEM_SERIALIZE         0
 #define APR_USE_FCNTL_SERIALIZE           0
-#define APR_USE_PROC_PTHREAD_SERIALIZE    0 
-#define APR_USE_PTHREAD_SERIALIZE         0 
+#define APR_USE_PROC_PTHREAD_SERIALIZE    0
+#define APR_USE_PTHREAD_SERIALIZE         0
 
 #define APR_HAS_FLOCK_SERIALIZE           0
 #define APR_HAS_SYSVSEM_SERIALIZE         0
@@ -351,7 +370,7 @@ extern "C" {
 
 /* Is the O_NONBLOCK flag inherited from listening sockets?
  */
-#define APR_O_NONBLOCK_INHERITED  1
+#define APR_O_NONBLOCK_INHERITED 1
 
 /* Typedefs that APR needs. */
 
@@ -623,18 +642,20 @@ typedef  int         gid_t;
      && (*(const apr_uint32_t *)(const void *)(&(a)->s6_addr[8]) == ntohl(0x0000ffff)))
 #endif
 
-#endif /* APR_HAS_IPV6 */
+#endif /* APR_HAVE_IPV6 */
 
 #ifdef __cplusplus
 }
 #endif
 
-/* Done with badly written headers
+/* Done with badly written headers, leave 'deprecated CRT' undeprecated
  */
 #if defined(_MSC_VER) && _MSC_VER >= 1200
 #pragma warning(pop)
+#if _MSC_VER >= 1400
 #pragma warning(disable: 4996)
 #endif
+#endif
 
 #endif /* WIN32 */
 



Mime
View raw message