Yes. If by heart murmur you mean a heart defect (they are not synonymous though), yes. There are certain medications that are associated with heart defects (even taking Aspirin can be dangerous) and alcohol or smoking can be a problem. Discuss with your doctor behaviors during pregnancy that can be harmful to your baby.
Rarely yes. Usually not. There are some medications however that may affect the baby's developing heart if you are taking them during pregnancy. Important to check with your OB doctor!