change offset type to bytes