If the poster of the comment hasn't replied/converted the comment to an answer after a "few" days (where the value of a "few" depends on all sorts of things) then you are free to post it as an answer yourself.
If you feel bad about getting reputation from someone else's work then mark the answer as Community Wiki and reference the comment and poster.
There are a few bits of denormalized data that determine whether a given answer is "accepted": the question knows of an accepted answer, each answer knows if it is accepted, and there are the actual "accept" votes as well. Occasionally, these can get out of sync with one another. That happened here (it shouldn't happen anymore, but this is an old question ...
First, you surely noted that your question was already asked in a comment in 2011, and that comment was already answered in the following comment:
Remember that an accepted answer is not an answer that is universally
accepted from all the users; it's the answer that is accepted from the
OP, who chooses the answer that helped him more. Only the OP can ...
The only person that can accept an answer (or change the accepted answer) is the question poster.
All "accepted answer" means is that "this answer helped me the most", nothing more and nothing else. It doesn't have to be best practise or even good practise, it just has to help the questioner out of his or her hole.