This article in the Kansas City Star argues that "socialist" is an old code word for "black." Perhaps that was once true, half a century ago. Nowadays socialism is most often associated in people's minds with either Scandinavia or China; residents of neither are black.
If a politician embraces redistributionist policies, those can fairly be called "socialist." Perhaps we should stop calling people racists unless their behavior is so extreme as to leave no doubt. For as Sigmund Freud said in making fun of some of his followers who saw so-called Freudian symbols everywhere, "Sometimes a cigar is just a cigar."