summaryrefslogtreecommitdiff
path: root/lib/libcrypto/asn1/a_utctm.c
diff options
context:
space:
mode:
authorMarkus Friedl <markus@cvs.openbsd.org>2004-04-08 08:03:16 +0000
committerMarkus Friedl <markus@cvs.openbsd.org>2004-04-08 08:03:16 +0000
commit5a78afb796c71a4c40ab9143bb17ca9cbeb0fd13 (patch)
tree798b4df03722b6dbd2be5083e0b5a7e189c24c25 /lib/libcrypto/asn1/a_utctm.c
parent7f2dfee3469d0814057ac4a8e518f5ed7ccc34b9 (diff)
merge 0.9.7d
Diffstat (limited to 'lib/libcrypto/asn1/a_utctm.c')
-rw-r--r--lib/libcrypto/asn1/a_utctm.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libcrypto/asn1/a_utctm.c b/lib/libcrypto/asn1/a_utctm.c
index 41f6d421bb2..999852dae52 100644
--- a/lib/libcrypto/asn1/a_utctm.c
+++ b/lib/libcrypto/asn1/a_utctm.c
@@ -200,7 +200,7 @@ ASN1_UTCTIME *ASN1_UTCTIME_set(ASN1_UTCTIME *s, time_t t)
return(NULL);
p=(char *)s->data;
- if ((p == NULL) || (s->length < len))
+ if ((p == NULL) || ((size_t)s->length < len))
{
p=OPENSSL_malloc(len);
if (p == NULL) return(NULL);
@@ -209,8 +209,8 @@ ASN1_UTCTIME *ASN1_UTCTIME_set(ASN1_UTCTIME *s, time_t t)
s->data=(unsigned char *)p;
}
- snprintf(p,len,"%02d%02d%02d%02d%02d%02dZ",ts->tm_year%100,
- ts->tm_mon+1,ts->tm_mday,ts->tm_hour,ts->tm_min,ts->tm_sec);
+ BIO_snprintf(p,len,"%02d%02d%02d%02d%02d%02dZ",ts->tm_year%100,
+ ts->tm_mon+1,ts->tm_mday,ts->tm_hour,ts->tm_min,ts->tm_sec);
s->length=strlen(p);
s->type=V_ASN1_UTCTIME;
#ifdef CHARSET_EBCDIC_not