Skip to content

Commit

Permalink
Remove utf8 encoding
Browse files Browse the repository at this point in the history
  • Loading branch information
grcooper committed Jan 13, 2025
1 parent 594991c commit 4b43068
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/dalli/protocol/buffered_io.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def read_line
terminator_index += TERMINATOR_SIZE
line = @buffer.byteslice(@offset, terminator_index - @offset)
@offset = terminator_index
line.force_encoding(Encoding::UTF_8)
line
end

# Reads the exact number of bytes from the buffer
Expand All @@ -44,7 +44,7 @@ def read(size)

str = @buffer.byteslice(@offset, size)
@offset += size
str.force_encoding(Encoding::UTF_8)
str
end

def write(str)
Expand Down

0 comments on commit 4b43068

Please sign in to comment.