diff --git a/ChangeLog b/ChangeLog index 23b100b196..a7b85cacf2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Tue Dec 28 17:18:17 2004 NAKAMURA Usaku + + * lib/net/telnet.rb (preprocess): remove NULL unless binmode. + Tue Dec 28 15:41:48 2004 Nobuyoshi Nakada * ext/nkf/nkf-utf8/nkf.c (reinit): should initialize all static diff --git a/lib/net/telnet.rb b/lib/net/telnet.rb index 05691de0f7..1ac5f25f09 100644 --- a/lib/net/telnet.rb +++ b/lib/net/telnet.rb @@ -438,6 +438,9 @@ module Net # combine EOL into "\n" string = string.gsub(/#{EOL}/no, "\n") unless @options["Binmode"] + # remove NULL + string = string.gsub(/#{NULL}/no, '') unless @options["Binmode"] + string.gsub(/#{IAC}( [#{IAC}#{AO}#{AYT}#{DM}#{IP}#{NOP}]| [#{DO}#{DONT}#{WILL}#{WONT}]