summaryrefslogtreecommitdiffstats
path: root/ext/openssl/ossl_hmac.c
diff options
context:
space:
mode:
authormatz <matz@ruby-lang.org>2004-12-15 06:35:55 +0000
committermatz <matz@ruby-lang.org>2004-12-15 06:35:55 +0000
commitd1e9636e8ff05851b66d074d10900185c92df788 (patch)
tree81aefa60fc02e145b36d92408324a9631ff3c286 /ext/openssl/ossl_hmac.c
parente6a0d25543528360ab35282ec037a61b24c05059 (diff)
downloadruby-openssl-history-d1e9636e8ff05851b66d074d10900185c92df788.tar.gz
* lib/set.rb (Set#==): [ruby-dev:25206]
* ext/openssl/ossl_digest.c (ossl_digest_initialize): [ruby-dev:25198] * utf8.c (utf8_is_mbc_ambiguous): [ruby-talk:123561] * utf8.c (utf8_mbc_to_normalize): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7563 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/openssl/ossl_hmac.c')
-rw-r--r--ext/openssl/ossl_hmac.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/openssl/ossl_hmac.c b/ext/openssl/ossl_hmac.c
index fb3d0a6..ca59175 100644
--- a/ext/openssl/ossl_hmac.c
+++ b/ext/openssl/ossl_hmac.c
@@ -62,8 +62,8 @@ ossl_hmac_initialize(VALUE self, VALUE key, VALUE digest)
{
HMAC_CTX *ctx;
- GetHMAC(self, ctx);
StringValue(key);
+ GetHMAC(self, ctx);
HMAC_Init_ex(ctx, RSTRING(key)->ptr, RSTRING(key)->len,
GetDigestPtr(digest), NULL);
@@ -92,8 +92,8 @@ ossl_hmac_update(VALUE self, VALUE data)
{
HMAC_CTX *ctx;
- GetHMAC(self, ctx);
StringValue(data);
+ GetHMAC(self, ctx);
HMAC_Update(ctx, RSTRING(data)->ptr, RSTRING(data)->len);
return self;