components/stdcxx/patches/046-time_put.cpp.patch
author Petr Sumbera <petr.sumbera@oracle.com>
Tue, 14 Mar 2017 02:44:36 -0700
changeset 7847 ec4c46e50642
parent 402 94ae4d75524c
permissions -rw-r--r--
25716748 Upgrade Apache Tomcat to version 8.5.11 25716728 problem in UTILITY/TOMCAT

--- stdcxx-4.2.1/src/time_put.cpp	2008-04-24 20:25:19.000000000 -0400
+++ stdcxx-4.2.1/src/time_put.cpp	2009-07-29 17:27:30.000000000 -0400
@@ -34,7 +34,10 @@
 
 #if (defined (__sun__) || defined (__sun) || defined (sun)) && defined (__EDG__)
     // get tzset() from <time.h>
-#   define _XOPEN_SOURCE
+#  if !defined(_XOPEN_SOURCE)
+#    define _XOPEN_SOURCE 500
+#    define _XPG5
+#  endif
 #endif
 
 #ifdef __CYGWIN__
@@ -2110,6 +2113,11 @@
     _RWSTD_ASSERT (   0 != tmb
                    || 'c' == fmt || 'r' == fmt || 'x' == fmt || 'X' == fmt);
 
+#if defined(_RWSTD_STRICT_SPARCV8_MUTEX_ALIGNMENT)
+#  pragma pack(8)
+#  pragma align 8(null_fmt)
+#endif
+
     static const union {
 #ifndef _RWSTD_NO_WCHAR_T
         wchar_t wide_data [1];
@@ -2117,6 +2125,10 @@
         char data [4];
     } null_fmt = { { 0 } };
 
+#if defined(_RWSTD_STRICT_SPARCV8_MUTEX_ALIGNMENT)
+#  pragma pack(0)
+#endif
+
     const __rw_time_t *ptime =
         _RWSTD_STATIC_CAST (const __rw_time_t*, facet->_C_data ());