minor bug in XOR gate