diff options
author | djm <> | 2011-11-03 02:32:23 +0000 |
---|---|---|
committer | djm <> | 2011-11-03 02:32:23 +0000 |
commit | 113f799ec7d1728f0a5d7ab5b0e3b42e3de56407 (patch) | |
tree | 26d712b25a8fa580b8f2dfc6df470ba5ffea9eb7 /src/lib/libcrypto/o_time.c | |
parent | 829fd51d4f8dde4a7f3bf54754f3c1d1a502f5e2 (diff) | |
download | openbsd-113f799ec7d1728f0a5d7ab5b0e3b42e3de56407.tar.gz openbsd-113f799ec7d1728f0a5d7ab5b0e3b42e3de56407.tar.bz2 openbsd-113f799ec7d1728f0a5d7ab5b0e3b42e3de56407.zip |
import OpenSSL 1.0.0e
Diffstat (limited to 'src/lib/libcrypto/o_time.c')
-rw-r--r-- | src/lib/libcrypto/o_time.c | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/src/lib/libcrypto/o_time.c b/src/lib/libcrypto/o_time.c index eecbdd19f0..9030fdef7a 100644 --- a/src/lib/libcrypto/o_time.c +++ b/src/lib/libcrypto/o_time.c | |||
@@ -64,12 +64,18 @@ | |||
64 | #include "o_time.h" | 64 | #include "o_time.h" |
65 | 65 | ||
66 | #ifdef OPENSSL_SYS_VMS | 66 | #ifdef OPENSSL_SYS_VMS |
67 | # include <libdtdef.h> | 67 | # if __CRTL_VER >= 70000000 && \ |
68 | # include <lib$routines.h> | 68 | (defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE) |
69 | # include <lnmdef.h> | 69 | # define VMS_GMTIME_OK |
70 | # include <starlet.h> | 70 | # endif |
71 | # include <descrip.h> | 71 | # ifndef VMS_GMTIME_OK |
72 | # include <stdlib.h> | 72 | # include <libdtdef.h> |
73 | # include <lib$routines.h> | ||
74 | # include <lnmdef.h> | ||
75 | # include <starlet.h> | ||
76 | # include <descrip.h> | ||
77 | # include <stdlib.h> | ||
78 | # endif /* ndef VMS_GMTIME_OK */ | ||
73 | #endif | 79 | #endif |
74 | 80 | ||
75 | struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result) | 81 | struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result) |
@@ -81,7 +87,7 @@ struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result) | |||
81 | so we don't even look at the return value */ | 87 | so we don't even look at the return value */ |
82 | gmtime_r(timer,result); | 88 | gmtime_r(timer,result); |
83 | ts = result; | 89 | ts = result; |
84 | #elif !defined(OPENSSL_SYS_VMS) | 90 | #elif !defined(OPENSSL_SYS_VMS) || defined(VMS_GMTIME_OK) |
85 | ts = gmtime(timer); | 91 | ts = gmtime(timer); |
86 | if (ts == NULL) | 92 | if (ts == NULL) |
87 | return NULL; | 93 | return NULL; |
@@ -89,7 +95,7 @@ struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result) | |||
89 | memcpy(result, ts, sizeof(struct tm)); | 95 | memcpy(result, ts, sizeof(struct tm)); |
90 | ts = result; | 96 | ts = result; |
91 | #endif | 97 | #endif |
92 | #ifdef OPENSSL_SYS_VMS | 98 | #if defined( OPENSSL_SYS_VMS) && !defined( VMS_GMTIME_OK) |
93 | if (ts == NULL) | 99 | if (ts == NULL) |
94 | { | 100 | { |
95 | static $DESCRIPTOR(tabnam,"LNM$DCL_LOGICAL"); | 101 | static $DESCRIPTOR(tabnam,"LNM$DCL_LOGICAL"); |