Project

General

Profile

Actions

Bug #15937

closed

Segmentation fault when String#initialize given same string with capacity field

Added by luke-gru (Luke Gruber) almost 5 years ago. Updated over 4 years ago.

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

Description

Reproduction steps:

string buffer corruption:

s = "mystring"
s.__send__(:initialize, s, capacity: 1000)
puts s

segfault:

s = "mystring that can't be embedded because it's too long and therefore must be allocated"
s.__send__(:initialize, s, capacity: 1000)

Thanks for your time :)

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0