@@ -142,40 +142,6 @@ static const short safe_years[SOLAR_CYCLE_LENGTH] = {
142
142
# define TIME64_TRACE3 (format , var1 , var2 , var3 ) ((void)0)
143
143
#endif
144
144
145
- /* Set up the mutexes for this file. There are no races possible on
146
- * non-threaded perls, nor platforms that naturally don't have them.
147
- * Otherwise, we need to have mutexes. If we have reentrant versions of the
148
- * functions below, they automatically will be substituted for the
149
- * non-reentrant ones. That solves the problem of the buffers being trashed by
150
- * another thread, but not of the environment or locale changing during their
151
- * execution. To do that, we only need a read lock (which prevents writing by
152
- * others). However, if we don't have re-entrant functions, we can gain some
153
- * measure of thread-safety by using an exclusive lock during their execution.
154
- * That will protect against any other use of the functions that use the
155
- * mutexes, which all of core should be using. */
156
- #ifdef USE_REENTRANT_API /* This indicates a platform where we need reentrant
157
- versions if have them */
158
- # ifdef PERL_REENTR_USING_LOCALTIME_R
159
- # define LOCALTIME_LOCK ENVr_LOCALEr_LOCK
160
- # define LOCALTIME_UNLOCK ENVr_LOCALEr_UNLOCK
161
- # else
162
- # define LOCALTIME_LOCK gwENVr_LOCALEr_LOCK
163
- # define LOCALTIME_UNLOCK gwENVr_LOCALEr_UNLOCK
164
- # endif
165
- # ifdef PERL_REENTR_USING_GMTIME_R
166
- # define GMTIME_LOCK ENVr_LOCALEr_LOCK
167
- # define GMTIME_UNLOCK ENVr_LOCALEr_UNLOCK
168
- # else
169
- # define GMTIME_LOCK gwENVr_LOCALEr_LOCK
170
- # define GMTIME_UNLOCK gwENVr_LOCALEr_UNLOCK
171
- # endif
172
- #else /* Reentrant not needed, so races not possible */
173
- # define LOCALTIME_LOCK NOOP
174
- # define LOCALTIME_UNLOCK NOOP
175
- # define GMTIME_LOCK NOOP
176
- # define GMTIME_UNLOCK NOOP
177
- #endif
178
-
179
145
static int S_is_exception_century (Year year )
180
146
{
181
147
const int is_exception = ((year % 100 == 0 ) && !(year % 400 == 0 ));
0 commit comments