Fix rsync prefix discovery