make it compile

This commit is contained in:
Kim "BKC" Carlbäcker 2018-07-05 00:33:49 +02:00
parent a79ae77156
commit 7635ba9038

View File

@ -260,7 +260,7 @@ func ParsePatch(maxLines, maxLineCharacters, maxFiles int, reader io.Reader) (*D
if err != nil && err != bufio.ErrBufferFull {
return nil, fmt.Errorf("PeekByte: %v", err)
}
newLine := bytes.IndexByte(peek, '\n');
newLine := bytes.IndexByte(peek, '\n')
if newLine == -1 {
// Instead of reading things, and copying memory around,
// we simply discard them (which doesn't allocate memory)