Rick, the doctor and Hershel know nothing about the disease--or if it will respond to antibiotics. The one thing everyone knows is that the disease leads to death, and reanimation as a walker. Rick must suffer from some kind of Pollyanna complex to think Carol is dangerous, when she ended a problem that had only one conclusion.
At that point, they only knew that two people died from it. And any doctor would know that even the worst diseases we've experienced in history didn't have a 100% mortality rate within a day. Basically, Carol had no way of knowing if they would die or not. And acting upon that lack of knowledge with murder isn't exactly in the right mind. She should have deferred to Hershel and Caleb, who were likely correct in diagnosing it as bacterial, and could have informed that most likely everyone in that cell block was already exposed.
Also, I don't think Rick thought Carol was dangerous so much as that her life was in danger from Tyreese or possibly others at the prison. The situation was likely to cause unrest.