merge revision(s) 41351: [Backport #9199]

	* ext/tk/tkutil/tkutil.c: use rb_sprintf(), rb_id2str(), and
	  rb_intern_str() instead of rb_intern() and RSTRING_PTR() with
	  RB_GC_GUARD(), to prevent temporary objects from GC.
	  [ruby-core:39000] [Bug #5199]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44564 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
merge revision(s) 44195: [Backport #7772]

	* util.c (ruby_qsort): fix potential stack overflow on a large
	  machine.  based on the patch by Conrad Irwin <conrad.irwin AT
	  gmail.com> at [ruby-core:51816].  [Bug #7772]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44565 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
merge revision(s) 43676: [Backport #8439]

	* test/openssl/test_cipher.rb (test_aes_gcm_wrong_tag): Don't use
	  String#succ because it can make modified (wrong) auth_tag longer
	  than 16 bytes.  The longer auth_tag makes that
	  EVP_CIPHER_CTX_ctrl (and internally aes_gcm_ctrl) fail.
	  [ruby-core:55143] [Bug #8439] reported by Vit Ondruch.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44566 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
merge revision(s) 43587: [Backport #8623]

	* tool/rbinstall.rb (Gem::Specification#collect): make stable
	  Gem::Specification.files in default .gemspecs the different order of
	  "files" in .gemspec files makes them different therefore possibly
	  conflicting in multilib scenario.  patch by vo.x (Vit Ondruch) at
	  [ruby-core:57544] [Bug #8623].


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44567 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
merge revision(s) 44570:

	tcltklib.c: create_ip_exc format argument

	* ext/tk/tcltklib.c (create_ip_exc): format argument must not be a
  dynamic string, not to contain unescaped %.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44575 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
merge revision(s) 44260: [Backport #9168] 

patch inspired from r44260 on trunk. [ruby-core:58652] [Bug #9168]

* gc.c (run_finalizer): clear th->errinfo before invoke finalizer and
  restore afterward.

* test/ruby/test_gc.rb (test_exception_in_finalizer): add test for
  above.

* vm_trace.c (rb_threadptr_exec_event_hooks_orig): clear th->errinfo
  before invoke hook.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44576 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
merge revision(s) 44598,44599,44600:

	/usr/lib/libc.so is not symlink on FreeBSD 10

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44655 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
merge revision(s) r44601:

	FreeBSD 10 SEGVs this less than 4M + 12K bytes.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44657 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
merge revision(s) 44569:44572,44576:44579,44581,44590:44594,44607,44608,44614,44615:

	iseq.c: linear search

	* iseq.c (iseq_type_from_id): linear search instead of hash lookup for
  small fixed number keys.
	------------------------------------------------------------------------
	r44570 | nobu | 2014-01-12 17:11:32 +0900 (Sun, 12 Jan 2014) | 4 lines

	tcltklib.c: create_ip_exc format argument

	* ext/tk/tcltklib.c (create_ip_exc): format argument must not be a
  dynamic string, not to contain unescaped %.
	------------------------------------------------------------------------
	r44571 | nobu | 2014-01-12 17:11:34 +0900 (Sun, 12 Jan 2014) | 5 lines

	stubs.c: library name strings

	* ext/tk/stubs.c (ruby_open_tcl_dll, ruby_open_tk_dll): make library
  names by string literal concatenation at compilation time, not by
  sprintf() at runtime.
	------------------------------------------------------------------------
	r44572 | nobu | 2014-01-12 17:11:36 +0900 (Sun, 12 Jan 2014) | 1 line

	ext: use rb_sprintf() and rb_vsprintf() with PRIsVALUE
	* ext/bigdecimal/bigdecimal.c (CLASS_NAME): macro to wrap
	  depending on PRIsVALUE for 1.9.  [Backport #9406]

	* ext/bigdecimal/bigdecimal.c (DECIMAL_SIZE_OF_BITS): fallback
	  definition for 2.1 or older.  [ruby-core:59750] [Backport #9406]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44659 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
merge revision(s) 44609,44610,44612,44613,44617:

	test_numeric.rb: coercion failures

	* test/ruby/test_numeric.rb (test_coerce): new assertions for
  failure of coercion.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44660 b2dd03c8-39d4-4d8f-98ff-823fe69b080e