Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
sanitizeStreamFilter breaks stream filters with new-line characters in their arguments #122
Trimming the string removes any trailing new-lines or other invisible characters like NULLs or white-space to be removed. This causes problems for filters that expect these characters to be used as arguments. For example a filter that uses str_replace to convert Windows-style line endings (\r\n) to Linux-style (\n) cannot be used because the trailing \n gets removed by the trim call.
This issue affects release 7.1.2 of thephpleague/csv and is known to be present on both PHP 5.6.10 on Ubuntu 14.04 and 5.5.25 on Windows 7.