Are the other students allowed to comment? Do you think the girl would have prevented the comments by wearing something different? If someone calls her a slut, would the lesson be "It doesn't matter if she is a slut or not?" No. Threats of violence are wrong. That does not translate into immorality being no big deal.
These bully stories are hand selected for a political and social agenda.
It's interesting you would choose this example...I was actually thinking of using it myself, but in a different context.
To answer your questions: Of course the students are allowed to comment, and the girl probably could have avoided the slut accusation by dressing differently. Does that make it appropriate to call her a slut? In this situation, I don't believe so.
There are tactful, dignified ways to express moral disapproval of something. This is especially true when the behavior being protested doesn't directly harm or threaten anyone else. So if I were a teacher and I heard a student call Ms. Spears a slut, I wouldn't have the namecaller suspended...but I would have a talk with her about the proper way to express yourself. I would also have a talk with Ms. Spears, except for the fact that I'd have a sexual harassment suit on my hands for doing so.
Just out of curiousity, suppose a student was wearing a regular tank top on a summer day, nothing too revealing. A Muslim student approaches her, holds out a sweater, and says "You better put this on, you dirty slut!" As a teacher, would you take a hands-off approach to this act of social boundary-setting?