[ruby-core:122191] [Ruby Bug#21351] Ruby master segfaults when initializing `Zlib::GzipReader`

Issue #21351 has been reported by st0012 (Stan Lo). ---------------------------------------- Bug #21351: Ruby master segfaults when initializing `Zlib::GzipReader` https://bugs.ruby-lang.org/issues/21351 * Author: st0012 (Stan Lo) * Status: Open * ruby -v: ruby 3.5.0dev (2025-05-13T14:16:58Z master bb180b87b4) +PRISM [arm64-darwin24] * Backport: 3.2: UNKNOWN, 3.3: UNKNOWN, 3.4: UNKNOWN ---------------------------------------- ### Ruby Version ``` ruby 3.5.0dev (2025-05-13T14:16:58Z master bb180b87b4) +PRISM [arm64-darwin24] last_commit=[Bug #21331] Prohibit modification during stlike loop ``` ### Steps to reproduce ``` $ ruby -e "require 'zlib'; Zlib::GzipReader.new('')" ``` ### C backtrace ``` /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_vm_bugreport+0xb6c) [0x102571c30] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_bug_for_fatal_signal+0x100) [0x1023a3ebc] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(sigsegv+0x84) [0x1024caae0] /usr/lib/system/libsystem_platform.dylib(_sigtramp+0x38) [0x1998fb624] /Users/hung-wulo/.gem/ruby/ruby-master/gems/zlib-3.2.1/lib/zlib.bundle(gzfile_new+0x30) [0x11d6d2efc] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_class_alloc+0xac) [0x1024366e8] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(vm_exec_core+0x38f4) [0x102549ac4] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_vm_exec+0x1b0) [0x102544e08] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_ec_exec_node+0x8c) [0x1023aef64] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(ruby_run_node+0x40) [0x1023aee8c] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(main+0x68) [0x1022f0980] ``` Full report is in the attached file ---Files-------------------------------- crash_report.txt (20.2 KB) -- https://bugs.ruby-lang.org/

Issue #21351 has been updated by st0012 (Stan Lo). Closed because this doesn't happen in `ruby 3.5.0dev (2025-05-19T17:34:29Z master a7ef9a44a6) +PRISM [arm64-darwin24]` anymore. ---------------------------------------- Bug #21351: Ruby master segfaults when initializing `Zlib::GzipReader` https://bugs.ruby-lang.org/issues/21351#change-113347 * Author: st0012 (Stan Lo) * Status: Closed * ruby -v: ruby 3.5.0dev (2025-05-13T14:16:58Z master bb180b87b4) +PRISM [arm64-darwin24] * Backport: 3.2: UNKNOWN, 3.3: UNKNOWN, 3.4: UNKNOWN ---------------------------------------- ### Ruby Version ``` ruby 3.5.0dev (2025-05-13T14:16:58Z master bb180b87b4) +PRISM [arm64-darwin24] last_commit=[Bug #21331] Prohibit modification during stlike loop ``` ### Steps to reproduce ``` $ ruby -e "require 'zlib'; Zlib::GzipReader.new('')" ``` ### C backtrace ``` /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_vm_bugreport+0xb6c) [0x102571c30] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_bug_for_fatal_signal+0x100) [0x1023a3ebc] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(sigsegv+0x84) [0x1024caae0] /usr/lib/system/libsystem_platform.dylib(_sigtramp+0x38) [0x1998fb624] /Users/hung-wulo/.gem/ruby/ruby-master/gems/zlib-3.2.1/lib/zlib.bundle(gzfile_new+0x30) [0x11d6d2efc] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_class_alloc+0xac) [0x1024366e8] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(vm_exec_core+0x38f4) [0x102549ac4] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_vm_exec+0x1b0) [0x102544e08] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(rb_ec_exec_node+0x8c) [0x1023aef64] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(ruby_run_node+0x40) [0x1023aee8c] /Users/hung-wulo/.rubies/ruby-master/bin/ruby(main+0x68) [0x1022f0980] ``` Full report is in the attached file ---Files-------------------------------- crash_report.txt (20.2 KB) -- https://bugs.ruby-lang.org/
participants (1)
-
st0012 (Stan Lo)