What the guy said was terrible, I can't defend that, but it might be worth your while to tell him, hey listen I don't appreciate you saying things about black people it was offensive and you're language was inappropriate. I'd ask him, why would you say something like that? You said before you thought he was a cool person, maybe you talking to him might help him see a different way. Of course there's no guarantee of that but it might be worth a try.