Improved active configuration detection.