Hello:
I work in a very small school. Many of my students have strong emotions and often bring them from one class to the next. I ask that they refrain from openly criticizing instructors-- as this leads to a volatile situation many times.
I will ask them to stop it and then after my class. I will see if they need to vent some frustration. I will encourage them to stay focused on their goals.
If this does happen I will alter my lesson plan some to bring in a motivation tool to lift up the spirits in the classroom.