Project

General

Profile

Actions

Bug #4380

closed

Encoding of result string for String#gsub! is not consistent for BINARY

Added by drbrain (Eric Hodel) about 13 years ago. Updated almost 13 years ago.

Status:
Closed
Target version:
-
ruby -v:
ruby 1.9.3dev (2011-02-07 trunk 30814) [x86_64-darwin10.6.0]
Backport:
[ruby-core:35141]

Description

=begin
When String#gsub! is called on a string in BINARY encoding the encoding may be changed to the replacement encoding.

Attached is a test patch.
=end


Files

test_string.rb.gsub_bang_encoding.patch (591 Bytes) test_string.rb.gsub_bang_encoding.patch Test patch to illustrate the bug. drbrain (Eric Hodel), 02/08/2011 04:50 AM

Related issues 1 (0 open1 closed)

Has duplicate Ruby master - Bug #4382: Encoding of result string for String#gsub! is not consistent for BINARYClosed02/08/2011Actions
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0