People think that if you distance yourself from someone (a friend or family member, for example), it means that you're angry with them. But it doesn't always work that way. Sometimes you genuinely love and care about them, but you've tried to work through things and can't. There are people who just don't understand that their actions have consequences and as a result they keep hurting the people in their life over and over.
Others just don't understand how to be a friend. There is a line between having patience with a friend, and continually getting beat up when you try. You shouldn't have to take mistreatment from anyone, so if someone is toxic, clueless, abusive, or just plain doesn't understand the golden rule, you have every right to move on.
Some people feel guilty about this when it comes to friendship. As if you should take poor treatment or bad behavior all in the name of friendship. But what they don't understand is that you can't always help people until they are ready to be helped. If you try with a friend over and over and you're getting emotionally pushed around in the process, there comes a time when you need to consider your own sanity and quality of life.
If you do end a friendship (for whatever reason) however, make sure that you have forgiven your friend. This isn't for your friend but for you. Here are some tips on how to do that.