瀏覽代碼

don't trim line endings in IRCStreamConn

Doesn't help if the line ends with regular \n only,
and the parser has to account for \r and \n anyway
tags/v2.2.0-rc1
Shivaram Lingamneni 3 年之前
父節點
當前提交
8cadc7340a
共有 1 個文件被更改,包括 0 次插入1 次删除
  1. 0
    1
      irc/ircconn.go

+ 0
- 1
irc/ircconn.go 查看文件

@@ -76,7 +76,6 @@ func (cc *IRCStreamConn) ReadLine() (line []byte, err error) {
76 76
 	if isPrefix {
77 77
 		return nil, errReadQ
78 78
 	}
79
-	line = bytes.TrimSuffix(line, crlf)
80 79
 	if globalUtf8EnforcementSetting && !utf8.Valid(line) {
81 80
 		err = errInvalidUtf8
82 81
 	}

Loading…
取消
儲存