<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/test/ripper/test_ripper.rb, branch v3_3_11</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>Fix memory leak for incomplete lambdas</title>
<updated>2023-08-09T18:06:58+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2023-08-09T16:18:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=0b8f15575a440f85ac686f5b0eae8f8b7c2b72e7'/>
<id>0b8f15575a440f85ac686f5b0eae8f8b7c2b72e7</id>
<content type='text'>
[Bug #19836]

The parser does not free the chain of `struct vtable`, which causes
memory leaks.

The following script reproduces this issue:

```
10.times do
  100_000.times do
    Ripper.parse("-&gt; {")
  end

  puts `ps -o rss= -p #{$$}`
end
```
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[Bug #19836]

The parser does not free the chain of `struct vtable`, which causes
memory leaks.

The following script reproduces this issue:

```
10.times do
  100_000.times do
    Ripper.parse("-&gt; {")
  end

  puts `ps -o rss= -p #{$$}`
end
```
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix memory leak in parser for incomplete tokens</title>
<updated>2023-08-09T18:06:58+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2023-08-09T15:03:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=5bc8fceca8d47ed1ef9c603c6531a408de36b60c'/>
<id>5bc8fceca8d47ed1ef9c603c6531a408de36b60c</id>
<content type='text'>
[Bug #19835]

The parser does not free the `tbl` of the `struct vtable` when there are
leftover `lvtbl` in the parser. This causes a memory leak.

The following script reproduces this issue:

```
10.times do
  100_000.times do
    Ripper.parse("class Foo")
  end

  puts `ps -o rss= -p #{$$}`
end
```
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[Bug #19835]

The parser does not free the `tbl` of the `struct vtable` when there are
leftover `lvtbl` in the parser. This causes a memory leak.

The following script reproduces this issue:

```
10.times do
  100_000.times do
    Ripper.parse("class Foo")
  end

  puts `ps -o rss= -p #{$$}`
end
```
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix null pointer access in Ripper#initialize</title>
<updated>2023-07-16T06:41:10+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2023-07-16T06:41:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=5c77402d885799e2465e291bf879dcfbd06ba77c'/>
<id>5c77402d885799e2465e291bf879dcfbd06ba77c</id>
<content type='text'>
In `rb_ruby_ripper_parser_allocate`, `r-&gt;p` is NULL between creating
`self` and `parser_params` assignment.  As GC can happen there, the
typed-data functions for it need to consider the case.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In `rb_ruby_ripper_parser_allocate`, `r-&gt;p` is NULL between creating
`self` and `parser_params` assignment.  As GC can happen there, the
typed-data functions for it need to consider the case.
</pre>
</div>
</content>
</entry>
<entry>
<title>Increase memory leak test timeout</title>
<updated>2023-06-28T17:47:48+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2023-06-28T15:35:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=27d3fa2af05cf6540ddb05bd65d5b12321737074'/>
<id>27d3fa2af05cf6540ddb05bd65d5b12321737074</id>
<content type='text'>
The test times out on some platforms, so increase the timeout.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The test times out on some platforms, so increase the timeout.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix memory leak in Ripper</title>
<updated>2023-06-28T13:50:51+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2023-06-27T18:34:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=a500eb9f8c487c9245d82f9b3c64cd3ddf44c836'/>
<id>a500eb9f8c487c9245d82f9b3c64cd3ddf44c836</id>
<content type='text'>
The following script leaks memory in Ripper:

```ruby
require "ripper"

20.times do
  100_000.times do
    Ripper.parse("")
  end

  puts `ps -o rss= -p #{$$}`
end
```
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The following script leaks memory in Ripper:

```ruby
require "ripper"

20.times do
  100_000.times do
    Ripper.parse("")
  end

  puts `ps -o rss= -p #{$$}`
end
```
</pre>
</div>
</content>
</entry>
<entry>
<title>Extract the wrapped value when yydebug [Bug #18075]</title>
<updated>2021-08-15T02:40:06+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2021-08-14T16:33:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=2aa6826e81ec880f5e98fa995e44fae0819be95d'/>
<id>2aa6826e81ec880f5e98fa995e44fae0819be95d</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>require 'stringio'</title>
<updated>2019-05-09T00:23:44+00:00</updated>
<author>
<name>NARUSE, Yui</name>
<email>naruse@airemix.jp</email>
</author>
<published>2019-05-09T00:23:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=f1486fea46cf36f1c936f5074a7251f29f9c1c5d'/>
<id>f1486fea46cf36f1c936f5074a7251f29f9c1c5d</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>parse.y: fix segv with Ripper#yydebug</title>
<updated>2019-03-19T02:35:50+00:00</updated>
<author>
<name>nobu</name>
<email>nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2019-03-19T02:35:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=e39f7e64b73f0506def7adc88226d6821608da54'/>
<id>e39f7e64b73f0506def7adc88226d6821608da54</id>
<content type='text'>
* parse.y (parser_token_value_print): in ripper, ID values are
  wrapped in NODE_RIPPER at set_yylval_name(), so print the Symbol
  wrapped together.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67305 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* parse.y (parser_token_value_print): in ripper, ID values are
  wrapped in NODE_RIPPER at set_yylval_name(), so print the Symbol
  wrapped together.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67305 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>ripper: add states of scanner</title>
<updated>2017-09-14T10:53:47+00:00</updated>
<author>
<name>nobu</name>
<email>nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2017-09-14T10:53:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=7df1e45bb6b4326da5c799dcf58d38f0a14362af'/>
<id>7df1e45bb6b4326da5c799dcf58d38f0a14362af</id>
<content type='text'>
* parse.y (ripper_state): add states of scanner to tokens from
  Ripper.lex and Ripper::Filter#on_*.  based on the patch by
  aycabta (Code Ahss) at [ruby-core:81789].  [Feature #13686]

* ext/ripper/tools/preproc.rb (prelude, usercode): generate EXPR_*
  constants from enums.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59896 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* parse.y (ripper_state): add states of scanner to tokens from
  Ripper.lex and Ripper::Filter#on_*.  based on the patch by
  aycabta (Code Ahss) at [ruby-core:81789].  [Feature #13686]

* ext/ripper/tools/preproc.rb (prelude, usercode): generate EXPR_*
  constants from enums.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59896 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>{ext,test}/ripper: Specify frozen_string_literal: true.</title>
<updated>2017-02-05T07:54:32+00:00</updated>
<author>
<name>kazu</name>
<email>kazu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2017-02-05T07:54:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=e3300dce829955390b5099c013ab4452a74ffd20'/>
<id>e3300dce829955390b5099c013ab4452a74ffd20</id>
<content type='text'>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57538 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57538 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
</feed>
