enforce a maxmimum path length and valid segments, 1.0.8