From: Richard Levitte Date: Wed, 5 Jun 2002 13:47:29 +0000 (+0000) Subject: It's not good to have a pointer point at something in an inner block. X-Git-Tag: OpenSSL_0_9_6e~26^2~96 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=b6fc2386f0e80e1280fd1ca8fb6b9ee848ae4f74;p=oweals%2Fopenssl.git It's not good to have a pointer point at something in an inner block. PR: 66 --- diff --git a/crypto/asn1/a_utctm.c b/crypto/asn1/a_utctm.c index ed2d827db2..dbb4a42c9d 100644 --- a/crypto/asn1/a_utctm.c +++ b/crypto/asn1/a_utctm.c @@ -222,6 +222,7 @@ ASN1_UTCTIME *ASN1_UTCTIME_set(ASN1_UTCTIME *s, time_t t) int ASN1_UTCTIME_cmp_time_t(const ASN1_UTCTIME *s, time_t t) { struct tm *tm; + struct tm data; int offset; int year; @@ -238,7 +239,7 @@ int ASN1_UTCTIME_cmp_time_t(const ASN1_UTCTIME *s, time_t t) t -= offset*60; /* FIXME: may overflow in extreme cases */ - { struct tm data; tm = OPENSSL_gmtime(&t, &data); } + tm = OPENSSL_gmtime(&t, &data); #define return_cmp(a,b) if ((a)<(b)) return -1; else if ((a)>(b)) return 1 year = g2(s->data);