<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/ext, branch ruby_2_5</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>merge revision(s) 47a1872cd8b901b8aab6dedce7fa3807c97d290d: [Backport #16681]</title>
<updated>2020-03-31T12:13:31+00:00</updated>
<author>
<name>usa</name>
<email>usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2020-03-31T12:13:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=6d20bf22fe82ec5c492c1822bc920be32831dd0d'/>
<id>6d20bf22fe82ec5c492c1822bc920be32831dd0d</id>
<content type='text'>
	Use osuosl instead of GitHub releases

	  Because the package provided by GitHub releases is different from sourceware.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67881 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	Use osuosl instead of GitHub releases

	  Because the package provided by GitHub releases is different from sourceware.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67881 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 61b7f86248bd121be2e83768be71ef289e8e5b90</title>
<updated>2020-03-31T11:40:08+00:00</updated>
<author>
<name>usa</name>
<email>usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2020-03-31T11:40:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=d5e7ea9e217568dfaf898ec82e8bc2c7ee2deb93'/>
<id>d5e7ea9e217568dfaf898ec82e8bc2c7ee2deb93</id>
<content type='text'>
	* ext/socket/init.c: do not return uninitialized buffer
	  Resize string buffer only if some data is received in
	  BasicSocket#read_nonblock and some methods.

	Co-Authored-By: Samuel Williams &lt;samuel.williams@oriontransfer.co.nz&gt;


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67877 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	* ext/socket/init.c: do not return uninitialized buffer
	  Resize string buffer only if some data is received in
	  BasicSocket#read_nonblock and some methods.

	Co-Authored-By: Samuel Williams &lt;samuel.williams@oriontransfer.co.nz&gt;


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67877 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 62743: [Backport #16687]</title>
<updated>2020-03-30T22:44:13+00:00</updated>
<author>
<name>usa</name>
<email>usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2020-03-30T22:44:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=209f34515819ae4147bbd76e8b8efa9f6261cf1d'/>
<id>209f34515819ae4147bbd76e8b8efa9f6261cf1d</id>
<content type='text'>
	Fix FrozenError on `Ripper.slice`

	Currently `Ripper.slice` raises a FrozenError

	```ruby
	require 'ripper'
	p Ripper.slice('foo', 'ident')
	```

	```
	/path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:193:in `concat': can't modify frozen String (FrozenError)
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:193:in `block in compile'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:190:in `scan'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:190:in `compile'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:169:in `initialize'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:151:in `new'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:151:in `token_match'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:144:in `slice'
		from /tmp/tmp.kb4cnhvum2/test.rb:2:in `&lt;main&gt;'
	```

	This patch will fix the problem.

	[Fix GH-1837]

	From: Masataka Pocke Kuwabara &lt;kuwabara@pocke.me&gt;

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67871 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	Fix FrozenError on `Ripper.slice`

	Currently `Ripper.slice` raises a FrozenError

	```ruby
	require 'ripper'
	p Ripper.slice('foo', 'ident')
	```

	```
	/path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:193:in `concat': can't modify frozen String (FrozenError)
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:193:in `block in compile'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:190:in `scan'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:190:in `compile'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:169:in `initialize'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:151:in `new'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:151:in `token_match'
		from /path/to/g/lib/ruby/2.6.0/ripper/lexer.rb:144:in `slice'
		from /tmp/tmp.kb4cnhvum2/test.rb:2:in `&lt;main&gt;'
	```

	This patch will fix the problem.

	[Fix GH-1837]

	From: Masataka Pocke Kuwabara &lt;kuwabara@pocke.me&gt;

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67871 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 36e9ed7fef6eb2d14becf6c52452e4ab16e4bf01: [Backport #16698]</title>
<updated>2020-03-30T22:22:10+00:00</updated>
<author>
<name>usa</name>
<email>usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2020-03-30T22:22:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=b379ecd8b6832dfcd5dad353b6bfd41701e2d678'/>
<id>b379ecd8b6832dfcd5dad353b6bfd41701e2d678</id>
<content type='text'>
	backport 80b5a0ff2a7709367178f29d4ebe1c54122b1c27 partially as a
	 securify fix for CVE-2020-10663. The patch was provided by Jeremy Evans.

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

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	backport 80b5a0ff2a7709367178f29d4ebe1c54122b1c27 partially as a
	 securify fix for CVE-2020-10663. The patch was provided by Jeremy Evans.

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

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 6a2d779027818eda418c9118f700b36816e833a5: [Backport #16681]</title>
<updated>2020-03-30T22:05:30+00:00</updated>
<author>
<name>usa</name>
<email>usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2020-03-30T22:05:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=fdffe91d462b04b5873fd9be27698998609a0493'/>
<id>fdffe91d462b04b5873fd9be27698998609a0493</id>
<content type='text'>
	Switch to download libffi source package to github releases from
	 sourceware.org

	[Bug #16681]
	(cherry picked from commit 86022167461dc90b70164e2bb23316959bbfd6ba)

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67867 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	Switch to download libffi source package to github releases from
	 sourceware.org

	[Bug #16681]
	(cherry picked from commit 86022167461dc90b70164e2bb23316959bbfd6ba)

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67867 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 203b7fa1ae8cc40d41c38d684f70b3fea7fae813,0131fab749fb76800de09e49a6abf910201c5b58,9c0cd5c569ba22bc68d1a77ad6580a275cd99639,c144d7215b3444fa36d28d540b60170a5b30743d: [Backport #16196]</title>
<updated>2020-03-30T21:37:50+00:00</updated>
<author>
<name>usa</name>
<email>usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2020-03-30T21:37:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=ac6dd2fecca31cdb6a06cf89eded6c9003ae8af5'/>
<id>ac6dd2fecca31cdb6a06cf89eded6c9003ae8af5</id>
<content type='text'>
	Guard static variable first

	* ext/openssl/ossl_asn1.c (Init_ossl_asn1): register the static
	  variable to grab an internal object, before creating the object.
	  otherwise the just-created object could get collected during the
	  global variable list allocation.  [Bug #16196]

	Slimed down test runtime by stressing openssl.so only [Bug #16196]


	Prefer rb_gc_register_mark_object

	* ext/openssl/ossl_asn1.c (Init_ossl_asn1): prefer
	  `rb_gc_register_mark_object`, which is better for constant
	  objects, over `rb_gc_register_address` for global/static
	  variables which can be re-assigned at runtime.  [Bug #16196]

	Skip very time consuming test [Bug #16196]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67863 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	Guard static variable first

	* ext/openssl/ossl_asn1.c (Init_ossl_asn1): register the static
	  variable to grab an internal object, before creating the object.
	  otherwise the just-created object could get collected during the
	  global variable list allocation.  [Bug #16196]

	Slimed down test runtime by stressing openssl.so only [Bug #16196]


	Prefer rb_gc_register_mark_object

	* ext/openssl/ossl_asn1.c (Init_ossl_asn1): prefer
	  `rb_gc_register_mark_object`, which is better for constant
	  objects, over `rb_gc_register_address` for global/static
	  variables which can be re-assigned at runtime.  [Bug #16196]

	Skip very time consuming test [Bug #16196]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67863 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 6333020fc924d3ae63775c032bbe8f57364cd42e:</title>
<updated>2019-11-08T08:29:32+00:00</updated>
<author>
<name>usa</name>
<email>usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2019-11-08T08:29:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=a4933de6549de70f04c2e54848fc271cf07a5ec5'/>
<id>a4933de6549de70f04c2e54848fc271cf07a5ec5</id>
<content type='text'>
	atime may not updated unless strictatime is set on macOS Catalina

	Cited from mount(8):

	```
	strictatime
	        Always update the file access time when reading from a
	        file. Without this option the filesystem may default to a
	        less strict update mode, where some access time updates
	        are skipped for performance reasons. This option could be
	        ignored if it is not supported by the filesystem.
	```

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67827 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	atime may not updated unless strictatime is set on macOS Catalina

	Cited from mount(8):

	```
	strictatime
	        Always update the file access time when reading from a
	        file. Without this option the filesystem may default to a
	        less strict update mode, where some access time updates
	        are skipped for performance reasons. This option could be
	        ignored if it is not supported by the filesystem.
	```

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67827 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 3f9562015e651735bfc2fdd14e8f6963b673e22a,c06ddfee878524168e4af07443217ed2f8d0954b,3b3b4a44e5: [Backport #15792]</title>
<updated>2019-08-26T15:58:57+00:00</updated>
<author>
<name>usa</name>
<email>usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2019-08-26T15:58:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=689a6a0a763517e5fa1fc078b2f8130e0af7c4c0'/>
<id>689a6a0a763517e5fa1fc078b2f8130e0af7c4c0</id>
<content type='text'>
	Get rid of indirect sharing

	* string.c (str_duplicate): share the root shared string if the
	  original string is already sharing, so that all shared strings
	  refer the root shared string directly.  indirect sharing can
	  cause a dangling pointer.

	[Bug #15792]

	str_duplicate: Don't share with a frozen shared string

	This is a follow up for 3f9562015e651735bfc2fdd14e8f6963b673e22a.
	Before this commit, it was possible to create a shared string which
	shares with another shared string by passing a frozen shared string
	to `str_duplicate`.

	Such string looks like:

	```
	 --------                    -----------------
	 | root | ------ owns -----&gt; | root's buffer |
	 --------                    -----------------
	     ^                             ^   ^
	 -----------                       |   |
	 | shared1 | ------ references -----   |
	 -----------                           |
	     ^                                 |
	 -----------                           |
	 | shared2 | ------ references ---------
	 -----------
	```

	This is bad news because `rb_fstring(shared2)` can make `shared1`
	independent, which severs the reference from `shared1` to `root`:

	```c
	/* from fstr_update_callback() */
	str = str_new_frozen(rb_cString, shared2);  /* can return shared1 */
	if (STR_SHARED_P(str)) { /* shared1 is also a shared string */
	    str_make_independent(str);  /* no frozen check */
	}
	```

	If `shared1` was the only reference to `root`, then `root` can be
	reclaimed by the GC, leaving `shared2` in a corrupted state:

	```
	 -----------                         --------------------
	 | shared1 | -------- owns --------&gt; | shared1's buffer |
	 -----------                         --------------------
	      ^
	      |
	 -----------                         -------------------------
	 | shared2 | ------ references ----&gt; | root's buffer (freed) |
	 -----------                         -------------------------
	```

	Here is a reproduction script for the situation this commit fixes.

	```ruby
	a = ('a' * 24).strip.freeze.strip
	-a
	p a
	4.times { GC.start }
	p a
	```

	 - string.c (str_duplicate): always share with the root string when
	   the original is a shared string.
	 - test_rb_str_dup.rb: specifically test `rb_str_dup` to make
	   sure it does not try to share with a shared string.

	[Bug #15792]

	Closes: https://github.com/ruby/ruby/pull/2159

	Update dependencies


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67766 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	Get rid of indirect sharing

	* string.c (str_duplicate): share the root shared string if the
	  original string is already sharing, so that all shared strings
	  refer the root shared string directly.  indirect sharing can
	  cause a dangling pointer.

	[Bug #15792]

	str_duplicate: Don't share with a frozen shared string

	This is a follow up for 3f9562015e651735bfc2fdd14e8f6963b673e22a.
	Before this commit, it was possible to create a shared string which
	shares with another shared string by passing a frozen shared string
	to `str_duplicate`.

	Such string looks like:

	```
	 --------                    -----------------
	 | root | ------ owns -----&gt; | root's buffer |
	 --------                    -----------------
	     ^                             ^   ^
	 -----------                       |   |
	 | shared1 | ------ references -----   |
	 -----------                           |
	     ^                                 |
	 -----------                           |
	 | shared2 | ------ references ---------
	 -----------
	```

	This is bad news because `rb_fstring(shared2)` can make `shared1`
	independent, which severs the reference from `shared1` to `root`:

	```c
	/* from fstr_update_callback() */
	str = str_new_frozen(rb_cString, shared2);  /* can return shared1 */
	if (STR_SHARED_P(str)) { /* shared1 is also a shared string */
	    str_make_independent(str);  /* no frozen check */
	}
	```

	If `shared1` was the only reference to `root`, then `root` can be
	reclaimed by the GC, leaving `shared2` in a corrupted state:

	```
	 -----------                         --------------------
	 | shared1 | -------- owns --------&gt; | shared1's buffer |
	 -----------                         --------------------
	      ^
	      |
	 -----------                         -------------------------
	 | shared2 | ------ references ----&gt; | root's buffer (freed) |
	 -----------                         -------------------------
	```

	Here is a reproduction script for the situation this commit fixes.

	```ruby
	a = ('a' * 24).strip.freeze.strip
	-a
	p a
	4.times { GC.start }
	p a
	```

	 - string.c (str_duplicate): always share with the root string when
	   the original is a shared string.
	 - test_rb_str_dup.rb: specifically test `rb_str_dup` to make
	   sure it does not try to share with a shared string.

	[Bug #15792]

	Closes: https://github.com/ruby/ruby/pull/2159

	Update dependencies


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67766 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 67200: [Backport #15648]</title>
<updated>2019-03-13T00:32:12+00:00</updated>
<author>
<name>nagachika</name>
<email>nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2019-03-13T00:32:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=4fd078646b36285c2812113fe78ec8776c6141d4'/>
<id>4fd078646b36285c2812113fe78ec8776c6141d4</id>
<content type='text'>
	Add ignored_sp event

	* ext/ripper/lib/ripper/lexer.rb (Ripper::Lexer): add ignored_sp
	  event which will be fired from Ripper::Lexer#on_heredoc_dedent
	  method.  [ruby-core:91727] [Bug #15648]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67242 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	Add ignored_sp event

	* ext/ripper/lib/ripper/lexer.rb (Ripper::Lexer): add ignored_sp
	  event which will be fired from Ripper::Lexer#on_heredoc_dedent
	  method.  [ruby-core:91727] [Bug #15648]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67242 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 64636,64637: [Backport #15659]</title>
<updated>2019-03-12T12:59:25+00:00</updated>
<author>
<name>nagachika</name>
<email>nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2019-03-12T12:59:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=a648423e271f7bb24bee730101b3b6d4051cd599'/>
<id>a648423e271f7bb24bee730101b3b6d4051cd599</id>
<content type='text'>
	AIX doesn't set OptionLength for boolean options

	https://rubyci.org/logs/rubyci.s3.amazonaws.com/aix71_ppc/ruby-trunk/log/20180904T103302Z.fail.html.gz
	https://www.ibm.com/support/knowledgecenter/ja/ssw_aix_72/com.ibm.aix.commtrf2/getsockopt.htm

	fix typo

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67228 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	AIX doesn't set OptionLength for boolean options

	https://rubyci.org/logs/rubyci.s3.amazonaws.com/aix71_ppc/ruby-trunk/log/20180904T103302Z.fail.html.gz
	https://www.ibm.com/support/knowledgecenter/ja/ssw_aix_72/com.ibm.aix.commtrf2/getsockopt.htm

	fix typo

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67228 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
</feed>
