FONTANA (CBSLA) — A playful German Shepherd puppy discovered the true meaning of “between a rock and a hard place.”

A 3-month-old puppy became wedged Thursday between a wall and a pipe, and needed assistance from firefighters and animal services officers in Fontana.

Fontana police say the pipe turned out to be a gas line, so the service had to be turned off before any rescue attempt.

After several attempts, the puppy was freed and returned to his appreciative owner.