fixes for finding discontinuous switch points for quadratic constraints