Secure Two-party computation
The protocol that you described computes the XOR function $a\oplus b$ in the presence of semi-honest adversaries. However, this function completely reveals the other party's input given your own input. Thus, no privacy is actually preserved. However, this is due to the definition of the ideal functionality and not a problem with the protocol.