It seems that due to upper respiratory tract
infection there might be having edema on vocal cord giving rise to hoarseness
Now this infection produced lower respiratory tract infection.
Consult your doctor and with one course of higher antibiotic will cure your both problems.
Ok and take care.