[ruby/openssl] ssl: adjust styles of ossl_start_ssl()

Expand tabs, insert some spaces, and adjust indentation of switch-case
to match Ruby's style.

https://github.com/ruby/openssl/commit/10833aa8f6
This commit is contained in:
Kazuki Yamaguchi 2023-06-07 15:52:52 +09:00
parent af67ced3b0
commit 66a70582f4

View File

@ -1765,7 +1765,7 @@ ossl_start_ssl(VALUE self, int (*func)(SSL *), const char *funcname, VALUE opts)
GetSSL(self, ssl); GetSSL(self, ssl);
VALUE io = rb_attr_get(self, id_i_io); VALUE io = rb_attr_get(self, id_i_io);
for(;;){ for (;;) {
ret = func(ssl); ret = func(ssl);
cb_state = rb_attr_get(self, ID_callback_state); cb_state = rb_attr_get(self, ID_callback_state);
@ -1778,7 +1778,7 @@ ossl_start_ssl(VALUE self, int (*func)(SSL *), const char *funcname, VALUE opts)
if (ret > 0) if (ret > 0)
break; break;
switch((ret2 = ssl_get_error(ssl, ret))){ switch ((ret2 = ssl_get_error(ssl, ret))) {
case SSL_ERROR_WANT_WRITE: case SSL_ERROR_WANT_WRITE:
if (no_exception_p(opts)) { return sym_wait_writable; } if (no_exception_p(opts)) { return sym_wait_writable; }
write_would_block(nonblock); write_would_block(nonblock);