A shepherd sees a wolf immediately attacking the flock while praying. What does the source permit?

Permissible Acts in Prayer and When Prayer May or Must Be Stopped