5798 Commits
Author SHA1 Message Date
usa 47165eed26 merge revision(s) 62991,63000:
unixsocket.c: check NUL bytes

	* ext/socket/unixsocket.c (rsock_init_unixsock): check NUL bytes.
	  https://hackerone.com/reports/302997

	unixsocket.c: abstract namespace

	* ext/socket/unixsocket.c (unixsock_path_value): fix r62991 for
	  Linux abstract namespace.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@63018 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-28 14:36:23 +00:00
usa d629ce0baa * ext/json: bump to version 1.8.1.1. [Backport #13853]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@59904 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-09-14 11:44:37 +00:00
usa 5450329ad1 asn1: fix out-of-bounds read in decoding constructed objects
* OpenSSL::ASN1.{decode,decode_all,traverse}: have a bug of
  out-of-bounds read. int_ossl_asn1_decode0_cons() does not give the
  correct available length to ossl_asn1_decode() when decoding the
  inner components of a constructed object. This can cause
  out-of-bounds read if a crafted input given.

Reference: https://hackerone.com/reports/170316
https://github.com/ruby/openssl/commit/1648afef33c1d97fb203c82291b8a61269e85d3b


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@59903 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-09-14 11:41:59 +00:00
usa 366c5481e6 * ext/psych/yaml: update libyaml to 0.1.7.
* ext/psych/psych.gemspec: bump version to 2.0.8.1.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@59793 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-09-09 12:24:22 +00:00
usa 03ab27a83e merge revision(s) 58020: [Backport #10936]
date_core.c: fix error in DateTime docs

	* ext/date/date_core.c: [DOC] fix format string for DateTime#rfc3339.
	  Reported by Andreas Rayo Kniep.  [ruby-core:68418] [Bug #10936]

	* ext/date/date_core.c: [DOC] ditto for DateTime#iso8601 and
	  DateTime#xmlschema; other small improvements.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@58128 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-03-25 18:55:01 +00:00
usa 950758b028 merge revision(s) 57737: [Backport #13225]
date_core.c: expand docs for Date shifting

	* ext/date/date_core.c: [DOC] expand docs for Date shifting

	  * add examples for Date#>> and Date#<< that clarify some edge cases
	  * add examples for Date#next_year and Date#prev_year
	  * add cross references to Date#>> and Date#<<

	  [ruby-core:79584] [Bug #13225]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@58125 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-03-25 18:36:29 +00:00
usa 1bd1e84388 merge revision(s) 57265,57266: [Backport #13081]
win32/resolv.rb: ad hoc workaround

	* ext/win32/lib/win32/resolv.rb (Win32::Resolv::SZ): an ad hoc
	  workaround for broken registry.  SearchList and other registry
	  values must be REG_SZ, or Windows ignores anything in those
	  values otherwise.  [ruby-dev:49924] [Bug #13081]
	  https://github.com/rubygems/rubygems/issues/1700
	win32/registry.rb: registry type names

	* ext/win32/lib/win32/registry.rb (Win32::Registry#read): show
	  registry type names instead of numeric values.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@58119 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-03-25 18:22:34 +00:00
usa d014f463cf merge revision(s) 57477,57478,57479,57492: [Backport #12405]
use TRUE/FALSE.

	define rb_thread_sleep_deadly_allow_spurious_wakeup().

	* thread.c, thread_sync.c: define new function
	  rb_thread_sleep_deadly_allow_spurious_wakeup() and use it instead of
	  using sleep_forever() directly.

	allow Queue operation in trap.

	* thread_sync.c: allow spurious wakeup to check Queue status just after trap.
	  [Bug #12405]

	* test/thread/test_queue.rb: add a test for it.

	test_queue.rb: fix portability

	* test/thread/test_queue.rb (test_queue_with_trap): fix
	  portability.  use SIGINT instead of SIGUSR2 which is supported
	  on not all platforms.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@58115 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-03-25 18:07:08 +00:00
usa 3358185367 merge revision(s) 57549: [Backport #13193]
date_core.c: [DOC] revise docs [ci skip]

	* fix malformed rdoc for Date#today, Date._strptime,
	  and DateTime._strptime
	* add code examples for Date#<< and Date#>> to demonstrate
	  that different dates can result in the same return value
	* use Date::ITALY in call-seq instead of only ITALY
	* fix some copy/paste mistakes where Date should be DateTime
	* fix various errors and grammar
	* fix cross references and formatting

	[ruby-core:79433] [Bug #13193]
	Author:    Marcus Stollsteimer <sto.mar@web.de>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@58101 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-03-25 16:48:05 +00:00
usa 30238f9608 merge revision(s) 53064: [Backport #11810]
* ext/openssl/ossl_ssl.c (ssl_npn_select_cb_common): fix parsing
	  protocol list.
	  The protocol list from OpenSSL is not null-terminated.
	  patched by Kazuki Yamaguchi [Bug #11810] [ruby-core:72082]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@56798 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-11-15 06:33:36 +00:00
usa 3c61aab98b merge revision(s) 56559,56582,56584,56585: [Backport #12903]
* test/ruby/test_file.rb (TestFile#test_stat): fix noatime case.
	  [ruby-core:77943] [Bug #12903]

	* ext/-test/file/fs.c (get_atime_p): Updating of file access times
	  is enabled or not.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@56789 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-11-14 18:58:23 +00:00
usa a240b37c74 merge revision(s) 55074: [Backport #12868]
* ext/openssl/ossl.c (Init_openssl): register an ex_data index for
	  X509_STORE and X509_STORE_CTX respectively. Since they don't share
	  the ex_data index registry, we can't use the same index.
	  (ossl_verify_cb): use the the correct index.

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

	* ext/openssl/ossl_x509store.c (ossl_x509store_set_vfy_cb): ditto.
	  (ossl_x509stctx_verify): ditto.

	* ext/openssl/ossl.h (void ossl_clear_error): add extern declarations
	  of ossl_store_{ctx_,}ex_verify_cb_idx.

	* ext/openssl/openssl_missing.c: remove X509_STORE_set_ex_data and
	  X509_STORE_get_ex_data.

	* ext/openssl/openssl_missing.h: implement X509_STORE_get_ex_data,
	  X509_STORE_set_ex_data and X509_STORE_get_ex_new_index as macros.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@56727 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-11-11 22:36:50 +00:00
usa d5e556688e merge revision(s) 49495: [Backport #12183]
* ext/win32ole/win32ole.c (Init_win32ole): should not use atexit to
	  free allocated hash table to avoid error on Cygwin.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@56303 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-09-30 15:50:14 +00:00
usa c880452b7c merge revision(s) 55822: [Backport #12660]
* ext/openssl/ossl_ssl.c (ossl_ssl_write_internal):
	  avoid undefined behavior

	* test/openssl/test_pair.rb (test_write_zero): new test
	  [ruby-core:76751] [Bug #12660]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@56300 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-09-30 15:03:15 +00:00
usa 673a8b4859 merge revision(s) 55410: [Backport #12488]
* ext/date/date_strftime.c (date_strftime_with_tmx): reject too
	  large precision to get rid of buffer overflow.
	  reported by Guido Vranken <guido AT guidovranken.nl>.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55940 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-08-16 12:01:03 +00:00
usa a1af71552f merge revision(s) 55047: [Backport #12441]
* ext/openssl/ossl_bn.c (try_convert_to_bnptr): Extracted from
	  GetBNPtr(). This doesn't raise exception but returns NULL on error.
	  (GetBNPtr): Raise TypeError if conversion fails.
	  (ossl_bn_eq): Implement BN#==.
	  (ossl_bn_eql): #eql? should not raise TypeError even if the argument
	  is not compatible with BN.
	  (ossl_bn_hash): Implement BN#hash.

	* ext/openssl/ossl_bn.c (Init_ossl_bn): Define #== and #hash.

	* test/openssl/test_bn.rb: Test BN#eql?, #== and #hash


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55937 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-08-16 11:55:03 +00:00
usa ef62988ecc merge revision(s) 55175: [Backport #12428]
* ext/openssl/ossl_pkey_dh.c (ossl_dh_compute_key): Check that the DH
	  has 'p' (the prime) before calling DH_size(). We can create a DH with
	  no parameter but DH_size() does not check and dereferences NULL.
	  [ruby-core:75720] [Bug #12428]

	* ext/openssl/ossl_pkey_dsa.c (ossl_dsa_sign): Ditto. DSA_size() does
	  not check dsa->q.

	* ext/openssl/ossl_pkey_rsa.c (ossl_rsa_public_encrypt,
	  ossl_rsa_public_decrypt, ossl_rsa_private_encrypt,
	  ossl_rsa_private_decrypt): Ditto. RSA_size() does not check rsa->n.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55935 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-08-16 11:33:35 +00:00
usa fc5238a491 merge revision(s) 55434: [Backport #12401]
* common.mk (build-ext), ext/extmk.rb: use variable EXTENCS
	  different than ENCOBJS, to get rid of circular dependency.
	  build libencs when linking encodings statically.
	  [ruby-core:75618] [Bug #12401]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55931 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-08-16 06:03:51 +00:00
usa 643ef23752 merge revision(s) 55380: [Backport #12255]
* ext/json/lib/*.rb: Removed some comments. Because these are unnecessary
	  class description. [ci skip][Bug #12255][ruby-core:74835]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55928 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-08-16 05:07:27 +00:00
usa b2248a008f merge revision(s) 55797: [Backport #12645]
* ext/socket/option.c, ext/socket/rubysocket.h (inet_ntop): share
	  the fallback definition.  [ruby-core:76646] [Bug #12645]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55926 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-08-16 05:03:20 +00:00
usa ca75e7b97e merge revision(s) 54721: [Backport #12311]
* ext/date/date_core.c (Init_date_core): [DOC] Convert DateTime
	  documentation to RDoc from Markdown.
	  [ruby-core:75136] [Bug #12311]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55358 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-06-10 07:26:51 +00:00
usa 0a619ef7ef merge revision(s) 55123,55129,55130,55133,55136: [Backport #12414]
* ext/bigdecimal/bigdecimal.c (GetVpValueWithPrec): consider
	  non-finite float values not to raise FloatDomainError.
	  [ruby-core:75682] [Bug #12414]

	* ext/bigdecimal/bigdecimal.c (isfinite): isfinite does not always
	  exist.  fixed build error on Windows itroduced at r55123.
	  exist.  fixed build error on Windows introduced at r55123.

	* ext/bigdecimal/bigdecimal.c (isfinite): get rid of a warning on
	  cygwin. [Bug #12417][ruby-core:75691]

	* include/ruby/missing.h (isfinite): move from numeric.c.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55354 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-06-10 07:09:00 +00:00
usa f9a641fdd2 merge revision(s) 54755: [Backport #12313]
* encoding.c: Fix return value of `Encoding::ISO8859_1.name`
	  [Bug #12313][ruby-core:75147][ci skip]

	* ext/bigdecimal/bigdecimal.c: Fix code sample of `BigDecimal.new`


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54772 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-26 04:26:16 +00:00
usa ed01f3c71e Revert r54694 because of compatibility problem.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54702 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 10:21:16 +00:00
usa 42569dd48e merge revision(s) 54423,54489: [Backport #12201] [Backport #12202]
* ext/nkf/nkf-utf8/nkf.c: Merge upstream 4f3edf80a0.
	  patched by Anton Sivakov [Bug #12201] [Bug #12202]

	* ext/nkf/nkf-utf8/nkf.c (mime_putc): fix typo.
	  [Bug #12202] [ruby-core:74802]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54695 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 09:23:01 +00:00
usa 59fadede2b merge revision(s) 54169: [Backport #12189]
* ext/date/date_core.c (datetime_to_time): preserve timezone info
	  [Bug #12189] [Fix GH-1295]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54694 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 09:20:38 +00:00
usa dadc253d7e merge revision(s) 49576: [Backport #12288]
* ext/openssl/extconf.rb: check RAND_edg to support libressl.

	* ext/openssl/ossl_rand.c (ossl_rand_egd): define only if RAND_edg
	  is available.  [Fix GH-829]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54688 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 07:37:36 +00:00
usa 88efadca4a merge revision(s) 54611,54612: [Backport #12291]
* struct.c (struct_make_members_list): extract making member name
	  list from char* va_list, with creating symbols without
	  intermediate IDs.

	* struct.c (struct_make_members_list, rb_struct_s_def): member
	  names should be unique. [ruby-core:74971] [Bug #12291]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54685 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 06:59:00 +00:00
usa 8d9e1ca972 merge revision(s) 54529: [Backport #12264]
* ext/win32/lib/win32/registry.rb (DeleteValue, DeleteKey): fix
	  API names.  [ruby-core:74863] [Bug #12264]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54684 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 06:24:15 +00:00
usa b0f5d2eb2c merge revision(s) 54484: [Backport #12095]
* vm_core.h (rb_vm_struct): make at_exit a single linked list but
	  not RArray, not to mark the registered functions by the write
	  barrier.  based on the patches by Evan Phoenix.
	  [ruby-core:73908] [Bug #12095]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54683 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 06:18:03 +00:00
usa aef285f5df merge revision(s) 54465: [Backport #12237]
* thread.c (update_coverage): Do not track coverage in loaded files
	  after Coverage.result. Avoids out-of-bounds access. [Bug #12237]

	* ext/coverage/coverage.c (coverage_clear_result_i): document.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54680 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 06:09:28 +00:00
usa 658cd0871e merge revision(s) 54444: [Backport #12233]
* ext/date/date_core.c (Init_date_core): [DOC] fix misplaced doc
	  of DateTime.  [ruby-core:74729] [Bug #12233]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54678 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 06:03:06 +00:00
usa 1cca2abf35 merge revision(s) 50338: [Backport #12253]
tkutil.c: revert r48250

	* ext/tk/tkutil/tkutil.c (Init_tkutil): TkUtil::CallbackSubst and
  TkUtil::CallbackSubst::Info need the default allocator.
  [ruby-list:50115]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54672 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-22 05:04:37 +00:00
nagachika 6ee7fcf309 merge revision(s) 54258: [Backport #12182]
* ext/openssl/extconf.rb: check SSL_CTX_set_next_proto_select_cb
	  function rather than OPENSSL_NPN_NEGOTIATED macro. it exists
	  even if it is disabled by OpenSSL configuration.
	  [ruby-core:74384] [Bug #12182]

	* ext/openssl/ossl_ssl.c: update #ifdef(s) as above.

	* test/openssl/test_ssl.rb: skip NPN tests if NPN is disabled.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54428 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-29 20:36:59 +00:00
nagachika 82752cc1ce merge revision(s) 49154: [Backport #10384]
ext/-test-/dln/empty: move from ext/-test-/win32/dln

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54342 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-28 17:46:51 +00:00
nagachika 1d3af7a3fc merge revision(s) 54097: [Backport #12069]
* ext/openssl/ossl_ssl.c (ossl_sslctx_setup): document as MT-unsafe
	  [ruby-core:73803] [Bug #12069]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54332 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-28 16:20:43 +00:00
nagachika 4f8b6b00f8 merge revision(s) 54022: [Backport #11893]
* ext/tk/lib/tkextlib/tcllib/tablelist_tile.rb: fix method name typo.
	  [ruby-core:72513] [Bug #11893] The patch provided by Akira Matsuda.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54320 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-28 15:00:46 +00:00
nagachika c320aa7a2c merge revision(s) 54021: [Backport #11891]
* ext/tk/lib/tkextlib/tcllib/toolbar.rb: fix method name typo.
	  [ruby-core:72511] [Bug #11891] The patch provided by Akira Matsuda.
	  [ruby-core:72510] [Bug #11890] The patch provided by Akira Matsuda.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54319 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-28 14:58:34 +00:00
nagachika e42b19aa3a merge revision(s) 54020: [Backport #11890]
* ext/tk/lib/tkextlib/blt/tree.rb: fix method name typo.
	[ruby-core:72510] [Bug #11890] The patch provided by Akira Matsuda.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54318 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-28 14:57:42 +00:00
nagachika 9f2dd6a718 merge revision(s) 54018: [Backport #11886]
* ext/tk/lib/tk/menubar.rb: fix a typo in font name. [ruby-core:72505]
	  [Bug #11886] The patch provided by Akira Matsuda.

	* ext/tk/sample/*.rb: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-28 14:56:42 +00:00
nagachika a9b42f1744 merge revision(s) 54139: [Backport #12185]
* ext/socket/option.c (inspect_tcpi_msec): more accurate condition
	  for TCPI msec member inspection function.
	  [ruby-core:74388] [Bug #12185]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54247 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-24 11:52:00 +00:00
nagachika f548ea1f4f merge revision(s) 53677: [Backport #11877]
* ext/socket/socket.c (sock_gethostname): support unlimited size
	  hostname.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54070 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-09 15:14:30 +00:00
nagachika 7d25771f17 merge revision(s) 53561: [Backport #11958]
* ext/socket/option.c (sockopt_bool): relax boolean size to be one
	  too not only sizeof(int).  Winsock getsockopt() returns a single
	  byte as a boolean socket option.  [ruby-core:72730] [Bug #11958]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54067 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-09 13:45:33 +00:00
nagachika 83d705f6a0 merge revision(s) 51016,53329: [Backport #11885]
* ext/openssl/ossl_ssl.c (ossl_ssl_read_internal):
	  do not process kwargs in blocking mode

	* test/openssl/test_ssl.rb: test sysread

	* io.c (io_getpartial): remove unused kwarg from template

	* test/ruby/test_io.rb (test_readpartial_bad_args): new
	  [Bug #11885]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54045 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-08 20:27:01 +00:00
nagachika ebacc09894 merge revision(s) 53435: [Backport #11945]
* ext/stringio/stringio.c (strio_binmode): implement to set encoding

	* test/stringio/test_stringio.rb (test_binmode): new test
	  [ruby-core:72699] [Bug #11945]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54042 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-08 19:19:22 +00:00
nagachika 0df86c0b0a merge revision(s) 53299: [Backport #11870]
* cont.c, doc, man: fix common misspelling.
	  [ruby-core:72466] [Bug #11870]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54040 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-08 19:02:43 +00:00
nagachika cb37e4013e merge revision(s) 53259: [Backport #11862]
* ext/socket/init.c (rsock_init_sock): reject reserved FDs
	  [ruby-core:72445] [Bug #11862]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54039 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-08 18:51:58 +00:00
nagachika f429ee01d2 merge revision(s) 52605,53231,53244: [Backport #11854]
init.c: is_socket

	* ext/socket/init.c (is_socket): extract predicate to see if the
  given fd is a socket.
	* ext/socket/init.c (rsock_init_sock): check FD after validating

	* test/socket/test_basicsocket.rb (test_for_fd): new
	  [ruby-core:72418] [Bug #11854]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@54038 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-03-08 18:49:52 +00:00
nagachika 02262a559f merge revision(s) 53022: [Backport #11764]
* ext/tk/lib/multi-tk.rb: fix typos.
	  [Bug #11764][ruby-core:71800]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@53221 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-20 20:04:55 +00:00
nagachika 745950a764 merge revision(s) 53153:
* ext/fiddle/handle.c: check tainted string arguments.
	  Patch provided by tenderlove and nobu.

	* test/fiddle/test_handle.rb (class TestHandle): add test for above.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@53154 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-16 12:11:34 +00:00