on android the dmesg output includes 0d0a as the newline char, added
a fix that strips this out so it doesn't corrupt the html file