summaryrefslogtreecommitdiff
path: root/ext/openssl/ossl_rand.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-07-22 15:34:23 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-07-22 15:34:23 +0000
commit6c0f54029816b7df0ce67b78f0dbe382546953da (patch)
tree8f0564d72b69d73c44db04e177637f64bdee5b21 /ext/openssl/ossl_rand.c
parentd56885b43df3b4e9e67fc4a39cbaaaea6961d5d8 (diff)
* 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_rand.c')
-rw-r--r--ext/openssl/ossl_rand.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/openssl/ossl_rand.c b/ext/openssl/ossl_rand.c
index ad830fb..af61fe3 100644
--- a/ext/openssl/ossl_rand.c
+++ b/ext/openssl/ossl_rand.c
@@ -99,7 +99,7 @@ ossl_rand_bytes(VALUE self, VALUE len)
int n = NUM2INT(len);
str = rb_str_new(0, n);
- if (!RAND_bytes(RSTRING_PTR(str), n)) {
+ if (!RAND_bytes((unsigned char *)RSTRING_PTR(str), n)) {
ossl_raise(eRandomError, NULL);
}
@@ -118,7 +118,7 @@ ossl_rand_pseudo_bytes(VALUE self, VALUE len)
int n = NUM2INT(len);
str = rb_str_new(0, n);
- if (!RAND_pseudo_bytes(RSTRING_PTR(str), n)) {
+ if (!RAND_pseudo_bytes((unsigned char *)RSTRING_PTR(str), n)) {
ossl_raise(eRandomError, NULL);
}