From: nagachika00@... Date: 2019-08-18T05:21:40+00:00 Subject: [ruby-core:94410] [Ruby master Bug#16019] please backport df317151a5b4e0c5a30fcc321a9dc6abad63f7ed Issue #16019 has been updated by nagachika (Tomoyuki Chikanaga). Backport changed from 2.5: DONTNEED, 2.6: REQUIRED to 2.5: DONTNEED, 2.6: DONE ruby_2_6 r67744 merged revision(s) df317151a5b4e0c5a30fcc321a9dc6abad63f7ed. ---------------------------------------- Bug #16019: please backport df317151a5b4e0c5a30fcc321a9dc6abad63f7ed https://bugs.ruby-lang.org/issues/16019#change-80832 * Author: wanabe (_ wanabe) * Status: Closed * Priority: Normal * Assignee: * Target version: * ruby -v: * Backport: 2.5: DONTNEED, 2.6: DONE ---------------------------------------- `TracePoint#enable` can cause SEGV without df317151a5b4e0c5a30fcc321a9dc6abad63f7ed on ruby_2_6. ``` $ ((cd ../../; git checkout .); make install-nodoc -j4) >/dev/null 2>&1 $ ruby -v -e 'def foo; TracePoint.new(:b_return, &:disable).enable(target: method(:bar)); end;def bar; 100.times{ foo; foo }; end; bar' ruby 2.6.3p65 (2019-06-22 revision 67712) [x86_64-linux] double free or corruption (fasttop) Aborted (core dumped) $ ``` But it can't with df317151a5b4e0c5a30fcc321a9dc6abad63f7ed. ``` $ ((cd ../../; git checkout .; git show df317151a5b4e0c5a30fcc321a9dc6abad63f7ed vm_trace.c|patch -p1); make install-nodoc -j4) >/dev/null 2>&1 $ ruby -v -e 'def foo; TracePoint.new(:b_return, &:disable).enable(target: method(:bar)); end;def bar; 100.times{ foo; foo }; end; bar' ruby 2.6.3p65 (2019-06-22 revision 67712) [x86_64-linux] $ ``` I think ruby_2_5 doesn't need the commit because `TracePoint#enable` accepts "target:" since 2.6. -- https://bugs.ruby-lang.org/ Unsubscribe: