Граф коммитов

40177 Коммитов

Автор SHA1 Сообщение Дата
tenderlove dc9ca079bb * ext/openssl/lib/openssl/ssl.rb (module OpenSSL): raise a more
helpful exception when verifying the peer connection and an
  anonymous cipher has been selected. [ruby-core:68330] [Bug #10910]
  Thanks to Chris Sinjakli <chris@sinjakli.co.uk> for the patch.

* test/openssl/test_ssl.rb (class OpenSSL): test for change

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51409 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 18:29:17 +00:00
svn 6d98fba257 * 2015-07-28
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51408 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 15:18:08 +00:00
kazu 41b6c0aa44 fix a typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51407 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 15:17:53 +00:00
kazu 8b5f291527 fix typos [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51406 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 13:35:04 +00:00
nobu 21d35a4d44 test/unit.rb: suppress warnings
* test/lib/test/unit.rb (MiniTest::Unit::TestCase.test_order): get
  rid of warnings.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51405 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 12:00:10 +00:00
nobu bd8bb810c7 test/unit.rb: --test-order option
* test/lib/test/unit.rb (setup_options): add --test-order option
  to override the test order.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51404 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 07:28:36 +00:00
ko1 747b7b7316 * template/id.h.tmpl (ID2ATTRSET): remove an unused macro.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51403 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 04:25:11 +00:00
nobu 7d8ac59131 fiddle: clean dot dir
* ext/fiddle/depend (distclean-libffi): clean dot directory too.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51402 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 03:46:07 +00:00
nobu 50a585ed25 fiddle: unexpand LIBFFI_DIR
* ext/fiddle/extconf.rb: use LIBFFI_DIR instead of expanding it.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51401 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 03:45:11 +00:00
nobu c92f22588e common.mk: clean preludes
* common.mk (distclean-local): clean preludes in the build
  diretory, not by realclean.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51400 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 03:44:00 +00:00
nobu 0b8c716233 common.mk: fix clean order
* common.mk (clean, distclean): clean local files before platform
  directory, some files may exist there.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51399 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 03:42:12 +00:00
nobu b343148b5a common.mk: clean-local
* common.mk (clean-local): remove added files and a directory.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51398 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 03:41:55 +00:00
usa 08be34a969 commit miss
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51397 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 03:22:28 +00:00
usa f294fe3def * test/openssl/tset_ssl.rb: run tests on non-Unix platforms.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51396 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 03:21:53 +00:00
nobu 0f6b7c4c3b io/console/extconf.rb: fix typo
* ext/io/console/extconf.rb: fix typo, $nmake is "m" for MS, not
  "n".  check sys/ioctl.h iff necessary for tty.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51395 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 02:21:13 +00:00
svn cf337a6235 * 2015-07-27
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51394 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 01:56:09 +00:00
nobu 9a26485e40 Makefile.sub: fix clean-ext
* win32/Makefile.sub (clean-ext): fix usage of for /R, and adjust
  messages as other platforms.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51393 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-27 01:55:58 +00:00
nobu edf712bfd8 ossl_ssl.c: fix condition
* ext/openssl/ossl_ssl.c (ossl_ssl_alpn_protocol): fix condition
  to compile, needs ALPN to be available.  [Feature #9390]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51392 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-26 10:21:35 +00:00
nobu 288f6e1b89 vm_insnhelper.c: suppress a warning
* vm_insnhelper.c (vm_setivar): cast to long both side of a
  conditional expression to suppress a sign-compare warning.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51391 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-26 06:24:18 +00:00
nobu 46b39cb0ba revert r31760 and r31761
seems that rb_bug_errno() is called in sigpipe() intentionally.
https://gist.github.com/sorah/831169

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51390 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-26 05:37:59 +00:00
nobu 38e62df9f6 signal.c: discard SIGSYS
* signal.c (default_handler, Init_signal): discard SIGSYS, ENOSYS
  should raise a SystemCallError always instead.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51389 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-26 02:29:03 +00:00
nobu a894dc6a99 load.c: use enum
* load.c (rb_construct_expanded_load_path): use enum for the
  purpose.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51388 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-26 02:20:24 +00:00
tenderlove 86ff702957 * ext/openssl/ossl_ssl.c (ossl_call_servername_cb): set the ssl context
object returned by the servername callback on to the socket as an
  instance variable.  If the callback allocated a new context object
  and didn't keep a reference to it, it could be GC'd out from under
  the socket object.

* test/openssl/test_ssl.rb (class OpenSSL): test for change.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51387 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-26 01:29:02 +00:00
tenderlove 2de804b4d5 * test/openssl/test_ssl.rb (class OpenSSL): add test coverage around
OpenSSL::SSL::SSLContext#servername_cb

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51386 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-26 01:09:31 +00:00
hsbt c2a9c954f1 * gems/bundled_gems: update latest version of bundled power-assert.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51385 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-26 00:10:38 +00:00
hsbt 91092bd0e4 * test/rubygems/test_gem_remote_fetcher.rb: backport rubygems upstream
change for OpenSSL key length. see detail to
  https://github.com/rubygems/rubygems/pull/1290

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51384 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 23:49:35 +00:00
svn 0b9387aaa5 * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51383 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 23:36:01 +00:00
tenderlove b380c987e1 * ext/openssl/lib/openssl/pkey.rb: implement DEFAULT_512 and
DEFAULT_1024 constants in Ruby.

* ext/openssl/lib/openssl/ssl.rb (module OpenSSL): Ask PKey for the
  default DH callback since it aleady must check whether openssl has
  been compiled with DH support.

* ext/openssl/ossl_pkey_dh.c (OSSL_PKEY_BN): Remove C definitions of
  DEFAULT_512 and DEFAULT_1024

* ext/openssl/ossl_pkey_dh.c (Init_ossl_dh): ditto

* test/openssl/test_pkey_dh.rb (class OpenSSL): add test to ensure the
  Ruby definitions are the same as the C definitions were.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51382 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 23:35:49 +00:00
tenderlove 486e6e02c2 * ext/openssl/lib/openssl/ssl.rb (module OpenSSL): support
specifically setting the tmp_dh_callback to nil.

* ext/openssl/ossl_ssl.c (Init_ossl_ssl): ditto

* test/openssl/test_pair.rb (module OpenSSL): add a test

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51381 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 23:16:49 +00:00
tenderlove d9fcc9ba5e * ext/openssl/lib/openssl/ssl.rb (module OpenSSL): move the default
tmp_dh_callback Ruby code and set it as a default in `initialize`.

* ext/openssl/ossl_pkey_dh.c (static unsigned char DEFAULT_DH_512_GEN):
  move this constant to Ruby.

* ext/openssl/ossl_pkey_dh.c (static unsigned char DEFAULT_DH_1024_GEN):
  ditto

* ext/openssl/ossl_pkey_dh.c (Init_ossl_dh): ditto

* ext/openssl/ossl_ssl.c (ossl_tmp_dh_callback): ditto

* ext/openssl/ossl_ssl.c (ossl_sslctx_setup): tmp_dh_callback should
  always be set, so we can remove this conditional

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51380 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 22:51:20 +00:00
tenderlove ab9cd02f25 * test/openssl/test_pair.rb: add a test ensuring that the default DH
callback is used when no DH callback is specified.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51379 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 21:23:22 +00:00
tenderlove dec31ef3eb * ext/openssl/lib/openssl/ssl.rb (module OpenSSL): add missing
instance variables to squash warnings with alpn.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51378 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 19:53:16 +00:00
svn c62785b9fb * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51377 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 18:45:51 +00:00
svn ea474f5dd6 * 2015-07-26
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51376 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 18:45:18 +00:00
tenderlove c8884ebfe4 * ext/openssl/lib/openssl/ssl.rb (module OpenSSL): move
OpenSSL::SSL::SSLContext#initialize implementation to pure Ruby.

* ext/openssl/ossl_ssl.c (ossl_sslctx_initialize): ditto

* ext/openssl/ossl_ssl.c (Init_ossl_ssl): ditto

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51375 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 18:44:54 +00:00
nobu e02186f526 random.c: get rid of blocking
* random.c (fill_random_bytes_syscall): get rid of blocking when
  no entropy is available.  based on the patch by mame in
  [ruby-core:70114].  [Bug #11395]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51374 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 12:03:50 +00:00
nobu 6e54a6df22 iseq.c: fix type
* iseq.c (rb_iseq_disasm, iseq_data_to_ary): fix loop counter type
  for array length.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51373 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 02:18:32 +00:00
nobu 8101cc3de4 string.c: fill the terminator
* string.c (str_replace_shared_without_enc): fill the terminator
  of embedded strings in wide char encodings.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51372 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 02:05:34 +00:00
nobu 9e4b24d4f3 string.c: remove redundant call
* string.c (str_replace): remove redundant coderage copy as
  str_replace_shared already copys it.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51371 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 01:48:53 +00:00
nobu 502004f617 string.c: cmp orders
* string.c (fstring_cmp, rb_str_hash_cmp): compare lengths first,
  then encodings, and contents at last.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51370 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-25 01:48:47 +00:00
ko1 22be6d06ab * vm_core.h: size should be unsigned.
* rb_call_info_t::index
  * rb_iseq_constant_body::stack_max
  * rb_iseq_constant_body::local_size
  * rb_iseq_constant_body::param::size
  * rb_iseq_constant_body::local_table_size
  * rb_iseq_constant_body::is_size
  * rb_iseq_constant_body::callinfo_size
* iseq.h: same for iseq_catch_table::size.
* compile.c: catch up these fix.
* iseq.c: ditto.
* proc.c: ditto.
* vm.c: ditto.
* vm_args.c: ditto.
* vm_eval.c: ditto.
* vm_insnhelper.c: ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51369 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 21:44:14 +00:00
ko1 14428f09b1 * vm_core.h: constify rb_iseq_constant_body::line_info_table.
* iseq.c: catch up this fix.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51368 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 21:01:09 +00:00
ko1 efa31acaad * vm_core.h: constify rb_iseq_constant_body::param::opt_table and
rb_iseq_constant_body::param::keyword.
* compile.c: catch up this fix.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51367 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 20:58:09 +00:00
svn 18ef8181ae * 2015-07-25
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51366 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 19:49:35 +00:00
ko1 8fbf5dd9e5 * vm_core.h: constify rb_iseq_constant_body::catch_table.
* compile.c (iseq_set_exception_table): catch up this fix.
* iseq.c: ditto.
* vm.c (vm_exec): ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51365 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 19:49:16 +00:00
nobu 7d517ffc80 st.c: fix arguments order to compare
* st.c (EQUAL, st_delete_safe): fix arguments order to compare
  function, searching key is the first and stored key is the
  second always.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51364 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 12:29:57 +00:00
nobu b706810232 string.c: fstring must not be a shared string
* string.c (fstr_update_callback): fstring must not be a shared
  string, or the content without RSTRING_FSTR may be freed.
  [ruby-dev:49188] [Bug #11386]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51363 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 12:27:32 +00:00
ngoto 6f8d3709da * test/rinda/test_rinda.rb (RingIPv6#prepare_ipv6): prevent to use
IPv6 loopback interface for
  Rinda::TestRingFinger#test_make_socket_ipv6_multicast and
  Rinda::TestRingFinger#test_make_socket_ipv6_multicast_hops.
  The tests are skipped if there are no IPv6 devices other than the
  loopback device. [Bug #11394] [ruby-dev:49199]

* test/rinda/test_rinda.rb (test_make_socket_ipv6_multicast): ditto
  for Rinda::TestRingServer#test_make_socket_ipv6_multicast.
   
* test/rinda/test_rinda.rb (test_ring_server_ipv6_multicast): ditto
  for Rinda::TestRingServer#test_ring_server_ipv6_multicast.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51362 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 11:29:49 +00:00
svn 0ee5c9b7fe * 2015-07-24
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51361 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 07:38:47 +00:00
nobu 4ab69ebbd7 string.c: pool only bare strings in fstring
* string.c (fstr_update_callback): pool bare strings only.
* string.c (rb_fstring): return the original string with sharing a
  fstring if it has extra attributes, not the fstring itself.
  [ruby-dev:49188] [Bug #11386]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51360 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-07-24 07:38:37 +00:00