IMO, nowt wrong with flirting with/having sex with/hooking up with a married guy. Essentialy, it is his job to moderate his behaviour and keep his **** in his pants. If he can't do that, not your cop. You have no strings, he does.
But are there kids involved? If so, MOVE AWAY NOW. It is one thing to be instrumental is splitting up a marriage where one partner is unfaithful, another to tear apart a family and screw the kids up.
A marriage is based on trust. Trust must be great enough to surpass all obstacles.
So what you're doing is testing that trust. And what's wrong with that, eh? If he accepts, then they probably weren't meant to be together in the first place. If he doesn't, then he'll go back to his wife with his relationship strengthened, and that trust enhanced. Win-win! If she catches you at it, just tell her exactly what I've said: your flirting is for her own good. As is sleeping with him. Tell her that she'll probably thank you for it someday. If you're feeling audacious, ask for payment.