What does a vacuum leak cause?

Rough idling and sometimes kills the motor. It could also trip the check engine light to come on.