make memcpy handle 2d addresses