net: make prefix work like address wrapping