Added root detection.