People are split on this; some people think you should modify obviously incorrect answers, some people think edits should only be for formatting and the like and shouldn't actually change the meaning of an answer.
I'm personally in the second group: if an answer is wrong than leave a comment saying so and post your own answer with the correct information; there's no need to modify someone else's wrong answer when you have the ability to post your own. I only edit an answer if it's right and I want to improve it since it's likely people searching for that problem will want to use it. I also worry about people accidentally modifying a right answer to be wrong because the editor was actually the one who was mistaken, but so far I've never seen that happen
(I somewhat discussed this here as well, and agree with George's comment