aspnet / HttpAbstractions

[Archived] HTTP abstractions such as HttpRequest, HttpResponse, and HttpContext, as well as common web utilities. Project moved to https://github.com/aspnet/AspNetCore
Apache License 2.0
382 stars 193 forks source link

Fix trimming line if CR not directly before LF #1006

Closed richardhopton closed 6 years ago

richardhopton commented 6 years ago

If the line contains a CR in any location than directly before the LF it would detect a valid line and then trim 2 characters from the end of the line, losing a "real" character.

e.g. This line\r would be treated as valid\n would be accepted and the resultant line output would be This line\r would be treated as vali

Tratcher commented 6 years ago

(Tests re-started)