if (s == NULL)
return (NULL);
- ts = OPENSSL_gmtime(&t, &data);
+ ts = gmtime_r(&t, &data);
if (ts == NULL)
return (NULL);
struct tm *ts;
struct tm data;
- ts=OPENSSL_gmtime(&t,&data);
+ ts=gmtime_r(&t,&data);
if (ts == NULL) {
ASN1err(ASN1_F_ASN1_TIME_ADJ, ASN1_R_ERROR_GETTING_TIME);
return NULL;
if (s == NULL)
return(NULL);
- ts=OPENSSL_gmtime(&t, &data);
+ ts=gmtime_r(&t, &data);
if (ts == NULL)
return(NULL);
t -= offset*60; /* FIXME: may overflow in extreme cases */
- tm = OPENSSL_gmtime(&t, &data);
+ tm = gmtime_r(&t, &data);
#define return_cmp(a,b) if ((a)<(b)) return -1; else if ((a)>(b)) return 1
year = g2(s->data);
#include <string.h>
#include "o_time.h"
-struct tm *
-OPENSSL_gmtime(const time_t *timer, struct tm *result)
-{
- return gmtime_r(timer, result);
-}
-
/* Take a tm structure and add an offset to it. This avoids any OS issues
* with restricted date types and overflows which cause the year 2038
* problem.
time_t t1, t2;
time(&t1);
t2 = t1 + offset;
- OPENSSL_gmtime(&t2, &tm2);
- OPENSSL_gmtime(&t1, &tm1);
+ gmtime_r(&t2, &tm2);
+ gmtime_r(&t1, &tm1);
OPENSSL_gmtime_adj(&tm1, 0, offset);
if ((tm1.tm_year == tm2.tm_year) &&
(tm1.tm_mon == tm2.tm_mon) &&
#include <time.h>
-struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result);
int OPENSSL_gmtime_adj(struct tm *tm, int offset_day, long offset_sec);
#endif
if (s == NULL)
return (NULL);
- ts = OPENSSL_gmtime(&t, &data);
+ ts = gmtime_r(&t, &data);
if (ts == NULL)
return (NULL);
struct tm *ts;
struct tm data;
- ts=OPENSSL_gmtime(&t,&data);
+ ts=gmtime_r(&t,&data);
if (ts == NULL) {
ASN1err(ASN1_F_ASN1_TIME_ADJ, ASN1_R_ERROR_GETTING_TIME);
return NULL;
if (s == NULL)
return(NULL);
- ts=OPENSSL_gmtime(&t, &data);
+ ts=gmtime_r(&t, &data);
if (ts == NULL)
return(NULL);
t -= offset*60; /* FIXME: may overflow in extreme cases */
- tm = OPENSSL_gmtime(&t, &data);
+ tm = gmtime_r(&t, &data);
#define return_cmp(a,b) if ((a)<(b)) return -1; else if ((a)>(b)) return 1
year = g2(s->data);
#include <string.h>
#include "o_time.h"
-struct tm *
-OPENSSL_gmtime(const time_t *timer, struct tm *result)
-{
- return gmtime_r(timer, result);
-}
-
/* Take a tm structure and add an offset to it. This avoids any OS issues
* with restricted date types and overflows which cause the year 2038
* problem.
time_t t1, t2;
time(&t1);
t2 = t1 + offset;
- OPENSSL_gmtime(&t2, &tm2);
- OPENSSL_gmtime(&t1, &tm1);
+ gmtime_r(&t2, &tm2);
+ gmtime_r(&t1, &tm1);
OPENSSL_gmtime_adj(&tm1, 0, offset);
if ((tm1.tm_year == tm2.tm_year) &&
(tm1.tm_mon == tm2.tm_mon) &&
#include <time.h>
-struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result);
int OPENSSL_gmtime_adj(struct tm *tm, int offset_day, long offset_sec);
#endif