endline problem?
backport 5.0.4 as 4.8.4