What was the purpose of firing volleys into the air?

by ThisCouldBeYourName

Watching American Civil War or Revolutionary War documentaries or reenactments I see some of the back lines fire a volley into the air. What is the purpose for doing that?

My apologies if this has been asked, I didn't see it in the FAQ and my search (which was probably crappy) didn't pick up anything.

Elphinstone1842

That's a safety precaution that is only done in modern reenactments in case there is accidentally something in the barrel and because even a blank blackpowder charge fired at close range can burn or even kill someone. Historically soldiers would have always pointed their guns in the direction of the enemy when firing during a battle.

Source: Reenactment safety rules 7 B, D and E