summaryrefslogtreecommitdiffstats
path: root/ext/openssl/ossl_x509crl.c
diff options
context:
space:
mode:
authornobu <nobu@ruby-lang.org>2008-07-22 15:34:23 +0000
committernobu <nobu@ruby-lang.org>2008-07-22 15:34:23 +0000
commit6b543384262820398b1675318fbd580fcf73737e (patch)
tree8c16cd54c1edd8d32c46f5e7b2201084d488534b /ext/openssl/ossl_x509crl.c
parentf6a75eb4f712b9cab55cf0cad1a1a76d0255d710 (diff)
downloadruby-openssl-history-6b543384262820398b1675318fbd580fcf73737e.tar.gz
* ext/openssl: suppress warnings.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18168 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/openssl/ossl_x509crl.c')
-rw-r--r--ext/openssl/ossl_x509crl.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/ext/openssl/ossl_x509crl.c b/ext/openssl/ossl_x509crl.c
index be9ddac..1be9640 100644
--- a/ext/openssl/ossl_x509crl.c
+++ b/ext/openssl/ossl_x509crl.c
@@ -91,7 +91,7 @@ static VALUE
ossl_x509crl_initialize(int argc, VALUE *argv, VALUE self)
{
BIO *in;
- X509_CRL *crl;
+ X509_CRL *crl, *x = DATA_PTR(self);
VALUE arg;
if (rb_scan_args(argc, argv, "01", &arg) == 0) {
@@ -99,10 +99,12 @@ ossl_x509crl_initialize(int argc, VALUE *argv, VALUE self)
}
arg = ossl_to_der_if_possible(arg);
in = ossl_obj2bio(arg);
- crl = PEM_read_bio_X509_CRL(in, (X509_CRL **)&DATA_PTR(self), NULL, NULL);
+ crl = PEM_read_bio_X509_CRL(in, &x, NULL, NULL);
+ DATA_PTR(self) = x;
if (!crl) {
- BIO_reset(in);
- crl = d2i_X509_CRL_bio(in, (X509_CRL **)&DATA_PTR(self));
+ (void)BIO_reset(in);
+ crl = d2i_X509_CRL_bio(in, &x);
+ DATA_PTR(self) = x;
}
BIO_free(in);
if (!crl) ossl_raise(eX509CRLError, NULL);