summaryrefslogtreecommitdiff
path: root/ext/openssl/ossl_ssl_session.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/openssl/ossl_ssl_session.c')
-rw-r--r--ext/openssl/ossl_ssl_session.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/openssl/ossl_ssl_session.c b/ext/openssl/ossl_ssl_session.c
index b236e4d5f6..d5fdba6aed 100644
--- a/ext/openssl/ossl_ssl_session.c
+++ b/ext/openssl/ossl_ssl_session.c
@@ -107,7 +107,7 @@ static VALUE ossl_ssl_session_get_time(VALUE self)
if (t == 0)
return Qnil;
- return rb_funcall(rb_cTime, rb_intern("at"), 1, LONG2NUM(t));
+ return rb_funcall(rb_cTime, rb_intern("at"), 1, TIMET2NUM(t));
}
/*
@@ -126,14 +126,14 @@ static VALUE ossl_ssl_session_get_timeout(VALUE self)
t = SSL_SESSION_get_timeout(ctx);
- return ULONG2NUM(t);
+ return TIMET2NUM(t);
}
#define SSLSESSION_SET_TIME(func) \
static VALUE ossl_ssl_session_set_##func(VALUE self, VALUE time_v) \
{ \
SSL_SESSION *ctx; \
- time_t t; \
+ unsigned long t; \
\
GetSSLSession(self, ctx); \
\