Fixed bug when writing / reading byte arrays - wrong reader-/writer-pos