That is one of those situations where I like to do the nod and smile as the person runs their mouth and let whatever they are saying go in one ear and right out the other. Like GCisPC said, unless Jack has behaved that way towards you or given you any indication of not being the type of person that he is presenting himself to be, then leave it be. Your friendship with Jack is separate and different from Mary's friendship with Jack. Don't let her friendship seep into your own friendship with him.
Until he does/says something that conflicts with your values/morals/beliefs/ethics you let Mary run her mouth all she wants.