From 78f8f45901dc8069c505656e83c42a11565fbc6f Mon Sep 17 00:00:00 2001 From: Joshua Peek Date: Sun, 15 May 2011 13:37:29 -0500 Subject: [PATCH] Use read instead of readchar IO#readchar returns an Int on 1.8 --- lib/otnetstring.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/otnetstring.rb b/lib/otnetstring.rb index 9d46daa..fa1b7aa 100644 --- a/lib/otnetstring.rb +++ b/lib/otnetstring.rb @@ -6,7 +6,7 @@ def self.parse(io) length, byte = "", "0" while byte =~ /\d/ length << byte - byte = io.readchar + byte = io.read(1) end length = length.to_i case byte