Project

General

Profile

Actions

Feature #16090

closed

RUBY_ON_BUG envval to debug

Added by ko1 (Koichi Sasada) over 5 years ago. Updated over 5 years ago.

Status:
Closed
Assignee:
-
Target version:
-
[ruby-core:94216]

Description

How about to introduce RUBY_ON_BUG environment variable which specify the command launched at rb_bug()?

RUBY_ON_BUG='gdb -p' ruby ...

In this case, gdb -p [PID] is invoked when rb_bug() is called.
after that, we can spy the interpreter with gdb.

https://github.com/ruby/ruby/pull/2331

On my patch, it is limited to RUBY_DEVEL build.

Security risk

I'm not a professional about security, but it can introduce new security risk.
Comments are welcome.
This is why I made a ticket.

Thanks,
Koichi

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0