diff options
| author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-09-25 08:49:36 +0000 |
|---|---|---|
| committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-09-25 08:49:36 +0000 |
| commit | b643c55391c39bc77c9761981d72f8c1420af594 (patch) | |
| tree | 561d200048bc55f32b4d45dca73a65fcfd67bba3 | |
| parent | 498774d058b2d3a4ce2d5bd1d5398dcf5b86a52d (diff) | |
| download | ruby-b643c55391c39bc77c9761981d72f8c1420af594.tar.gz ruby-b643c55391c39bc77c9761981d72f8c1420af594.tar.xz ruby-b643c55391c39bc77c9761981d72f8c1420af594.zip | |
* ext/openssl/ossl.c (ossl_buf2str): fix type of 1st argument for
rb_protect.
* ext/openssl/ossl_hmac.c (ossl_hmac_digest): should return meaningful
value.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@4597 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | ChangeLog | 8 | ||||
| -rw-r--r-- | ext/openssl/ossl.c | 2 | ||||
| -rw-r--r-- | ext/openssl/ossl_hmac.c | 2 |
3 files changed, 10 insertions, 2 deletions
@@ -1,3 +1,11 @@ +Thu Sep 25 17:48:10 2003 NAKAMURA Usaku <usa@ruby-lang.org> + + * ext/openssl/ossl.c (ossl_buf2str): fix type of 1st argument for + rb_protect. + + * ext/openssl/ossl_hmac.c (ossl_hmac_digest): should return meaningful + value. + Thu Sep 25 09:00:00 2003 Nathaniel Talbott <ntalbott@ruby-lang.org> * lib/ostruct.rb: Added OpenStruct#==. diff --git a/ext/openssl/ossl.c b/ext/openssl/ossl.c index 9f605f016..497f2549f 100644 --- a/ext/openssl/ossl.c +++ b/ext/openssl/ossl.c @@ -132,7 +132,7 @@ ossl_buf2str(char *buf, int len) VALUE str; int status = 0; - str = rb_protect((VALUE(*)_(()))ossl_str_new, len, &status); + str = rb_protect((VALUE(*)_((VALUE)))ossl_str_new, len, &status); if(!NIL_P(str)) memcpy(RSTRING(str)->ptr, buf, len); OPENSSL_free(buf); if(status) rb_jump_tag(status); diff --git a/ext/openssl/ossl_hmac.c b/ext/openssl/ossl_hmac.c index 1e5d5bc09..0b4d8d9b5 100644 --- a/ext/openssl/ossl_hmac.c +++ b/ext/openssl/ossl_hmac.c @@ -124,7 +124,7 @@ ossl_hmac_digest(VALUE self) GetHMAC(self, ctx); hmac_final(ctx, &buf, &buf_len); - ossl_buf2str(buf, buf_len); + digest = ossl_buf2str(buf, buf_len); return digest; } |
