Skip to content

Commit

Permalink
adding idea from AutosoftDMS#42
Browse files Browse the repository at this point in the history
  • Loading branch information
aclima93 committed Apr 28, 2020
1 parent 186bc62 commit ad5fdee
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ final class ChunkBuffer {
func readLine() -> String? {
var line: String?

while let endIndex = buffer.index(of: "\n") {
while let endIndex = buffer.index(of: "\n") ?? buffer.index(of: "\n\r") {
let substring = buffer[..<endIndex]
buffer.removeSubrange(buffer.startIndex ..< buffer.index(after: endIndex))

Expand Down

0 comments on commit ad5fdee

Please sign in to comment.