~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to gnulib/mktime.c

Merged update-gnulib.

Show diffs side-by-side

added added

removed removed

Lines of Context:
38
38
 
39
39
#include <string.h>             /* For the real memcpy prototype.  */
40
40
 
41
 
#if defined(DEBUG)
 
41
#if DEBUG
42
42
# include <stdio.h>
43
43
# include <stdlib.h>
44
44
/* Make it work even if the system's libc has its own mktime routine.  */
139
139
  };
140
140
 
141
141
 
142
 
#ifndef mktime_internal
143
 
time_t mktime_internal (struct tm *tp,
144
 
                   struct tm *(*convert) (const time_t *, struct tm *),
145
 
                   time_t *offset);
146
 
#endif
147
 
 
148
142
#ifndef _LIBC
149
143
/* Portable standalone applications should supply a <time.h> that
150
144
   declares a POSIX-compliant localtime_r, for the benefit of older
296
290
  int mday = tp->tm_mday;
297
291
  int mon = tp->tm_mon;
298
292
  int year_requested = tp->tm_year;
299
 
  int isdst = tp->tm_isdst;
 
293
  /* Normalize the value.  */
 
294
  int isdst = ((tp->tm_isdst >> (8 * sizeof (tp->tm_isdst) - 1))
 
295
               | (tp->tm_isdst != 0));
300
296
 
301
297
  /* 1 if the previous probe was DST.  */
302
298
  int dst2;
528
524
libc_hidden_weak (timelocal)
529
525
#endif
530
526
 
531
 
#if defined(DEBUG)
 
527
#if DEBUG
532
528
 
533
529
static int
534
530
not_equal_tm (const struct tm *a, const struct tm *b)