Yes, he did, but I was commenting on why he didn’t learn it from Sanpe in book 5.
True. Then again, part of the blame still rests with Harry. Impatience and rash action was Harry's big weakness -- Snape correctly noted that he "lacked subtlety," and Harry got all peeved when occlumency didn't come to him immediately. He finally had to learn it for himself, by feel. Snape's own nastiness certainly didn't help matters, but Harry was partly to blame for it. For example, he never told anybody in a position to do something about it, about the way Snape was behaving. He simply gave up.