An invalid inference may have an accidentally true conclusion without becoming valid.

Semantic Fallacies: Defects of Matter, Form, and Predication