Come from the same panel? If they do and the respective circuit breakers are one directly over the other, then there should be no problem. If they are on opposite sides of the panel (across from each other) then you could be overloading the neutral wire. In other words, if the voltage from one hot wire to the other is 220v, then you are ok. if they measure almost no voltage, then you are not ok. If they are not from the same panel, this is bad, as someone could turn off the main breaker at one panel or the other, and the panel would still be "hot" from feedthrough from the relay coil. At any rate, the setup probably does not meet code.