Hi,
I must admit I'm not sure how or if the comparator interfere with the pins when the pins are configured as outputs. However I can't see the comparator pins being set to digital so it might be...