Even the 9/11 hijackers were trying, in their own sick way, to do something good. They were convinced that the United States was the Great Satan, so taking us down a notch would be an improvement (from their point of view). Unfortunately, they were so brainwashed and consumed by hate that they were unable to do something constructive that would strengthen the position of the oppressed people with whom they felt kinship. And in fact, thanks to their act of terrorism, Muslims are now more reviled and abused by Americans than ever before.
Other behaviors with a much lower magnitude of destructiveness are similarly performed with the best of intentions. A woman who remains in an abusive relationship is doing so because there is some way in which the relationship benefits her -- perhaps she doesn't believe she can survive on her own, and being with an abuser is better than being alone. Or a person who gets caught up in religious fanaticism -- there might be a void in that person's life that is filled by ascribing to this oppressive and rigid world view.
Like I was saying in an earlier post, thinking about others with compassion can help keep you from getting angry when people treat you poorly, but there's more to it than that. Understanding (which does not mean agreeing with) others' points of view can help you to figure out how best to relate to others.