diff options
| author | gotoyuzo <gotoyuzo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-03-09 11:26:49 +0000 |
|---|---|---|
| committer | gotoyuzo <gotoyuzo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-03-09 11:26:49 +0000 |
| commit | 88df6cf3475c40055cd1c6f01df7e863028d5d52 (patch) | |
| tree | 39cc3de532700f7c21a32bf5f7f2eb195a444509 /ext | |
| parent | ac5ecf5ca6328ca75bcc579cf727b3d4600a5ce0 (diff) | |
| download | ruby-88df6cf3475c40055cd1c6f01df7e863028d5d52.tar.gz ruby-88df6cf3475c40055cd1c6f01df7e863028d5d52.tar.xz ruby-88df6cf3475c40055cd1c6f01df7e863028d5d52.zip | |
* ext/openssl/ossl_ssl.c (ossl_start_ssl, ossl_ssl_write): call
rb_sys_fail if errno isn't 0. [ruby-dev:25831]
* ext/openssl/lib/openssl/cipher.rb: fix typo. [ruby-dev:24285]
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@8130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext')
| -rw-r--r-- | ext/openssl/lib/openssl/cipher.rb | 2 | ||||
| -rw-r--r-- | ext/openssl/ossl_ssl.c | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/ext/openssl/lib/openssl/cipher.rb b/ext/openssl/lib/openssl/cipher.rb index 11153104e..9f8776d6f 100644 --- a/ext/openssl/lib/openssl/cipher.rb +++ b/ext/openssl/lib/openssl/cipher.rb @@ -20,7 +20,7 @@ module OpenSSL module Cipher - %w(AES Cast5 BF DES Idea RC2 RC4 RC5).each{|cipher| + %w(AES CAST5 BF DES IDEA RC2 RC4 RC5).each{|cipher| eval(<<-EOD) class #{cipher} < Cipher def initialize(*args) diff --git a/ext/openssl/ossl_ssl.c b/ext/openssl/ossl_ssl.c index 01b44f321..efe2eb83a 100644 --- a/ext/openssl/ossl_ssl.c +++ b/ext/openssl/ossl_ssl.c @@ -462,7 +462,7 @@ ossl_start_ssl(VALUE self, int (*func)()) rb_io_wait_readable(fileno(fptr->f)); continue; case SSL_ERROR_SYSCALL: - rb_sys_fail(0); + if (errno) rb_sys_fail(0); default: ossl_raise(eSSLError, NULL); } @@ -567,7 +567,7 @@ ossl_ssl_write(VALUE self, VALUE str) rb_io_wait_readable(fileno(fptr->f)); continue; case SSL_ERROR_SYSCALL: - rb_sys_fail(0); + if (errno) rb_sys_fail(0); default: ossl_raise(eSSLError, "SSL_write:"); } |
