read_write_all: avoid arithmetic on void pointers.