A few changes suggested by the real-world test cases (which include
non-standard tags.  Apparently spaces are "close enough" to null bytes
for some coders.