(svn r25337) -Fix: saving only 8 bits of 16 causes endianness problems