From: Richard Levitte Date: Tue, 28 Apr 2009 12:50:32 +0000 (+0000) Subject: Reimplement time check for VMS to mimic the way it's done on Windows. X-Git-Tag: OpenSSL-fips-2_0-rc1~1703 X-Git-Url: https://git.openssl.org/?p=openssl.git;a=commitdiff_plain;h=3c3f98dc93260fd767645f339043e205741909f6 Reimplement time check for VMS to mimic the way it's done on Windows. Reason: gettimeofday() is deprecated. --- diff --git a/crypto/bio/bss_dgram.c b/crypto/bio/bss_dgram.c index e3967041b3..256868265c 100644 --- a/crypto/bio/bss_dgram.c +++ b/crypto/bio/bss_dgram.c @@ -61,15 +61,12 @@ #include #include -#ifdef OPENSSL_SYS_VMS -#include -#endif #define USE_SOCKETS #include "cryptlib.h" #include -#ifdef OPENSSL_SYS_WIN32 +#if defined(OPENSSL_SYS_WIN32) || defined(OPENSSL_SYS_VMS) #include #endif @@ -217,6 +214,11 @@ static int dgram_read(BIO *b, char *out, int outl) _ftime(&tb); curtime.tv_sec = (long)tb.time; curtime.tv_usec = (long)tb.millitm * 1000; +#elif defined(OPENSSL_SYS_VMS) + struct timeb tb; + ftime(&tb); + curtime.tv_sec = (long)tb.time; + curtime.tv_usec = (long)tb.millitm * 1000; #else gettimeofday(&curtime, NULL); #endif