Bacteria tend to pass from one person to another either via air or through surfaces. As such, this can be contagious. But check with your doctor for the pathogen that has caused pneumonia. Then you would get know whether you have the power to shed the pathogen