Use encoding/binary.ByteOrder to avoid some unsafe pointer use.