If a person unintentionally was a cause for the infection of another person or a patient through mingling with the other, and that led to his death, he does not bear any responsibility for his death.
However, one has to take his caution if he finds himself sick, in order not to spread the virus that he may bear.
On this issue, Dr. Jamal Badawi, Professor of Religious Studies, said:
“As described, the person is not even responsible for involuntary manslaughter. He should however seek the forgiveness of Allah and try to take precautions to protect the life and health of patients, especially vulnerable ones. He should check with his employer about required procedures in case a worker is sick. I am reasonably sure that every hospital must have some policies and procedures to that effect.”