There is always the chance of bystanders, especially in urban areas like Walmart parking lots. If I was under fire and couldn't confirm my target+what's beyond it, I would definitely be hesitant. I know that warning shots are universally contraindicated, but in such a situation (where there is already little to lose) a couple of shots fired in a 'more safe' direction might be enough to slow the attack.
The best way to prevent bystander impacts of bullets is to slow the bullet down as much as possible. When confronted by an armed attacker, by far the MOST safe method to do this is to use the perp's body to do so. True, most handgun projectiles can penetrate all the way through a person, but they are both heavily expanded and/or fragmented afterwards and traveling much slower.
The lack of safe directions is just one of the reasons warning shots are dumb. If the weapon is drawn, pointed, and defensive action is still needed (the aggressor didn't stop the aggressive action upon viewing the weapon), AND the requirements of a justified shoot have been met, the loop has been closed, and the safest shot for both the defender and bystanders is a CoM shot(s) on the aggressor. Remember the rules, do not point a weapon at something you are unwilling to destroy. If you are not confident that your shot will hit its target, practice more.
While the above has exceptions, the CCW holder's wait and re-assess at the Oregon mall incident as an example, where while the shoot was justified, he had the necessary cover and time (due to the aggressor having a malfunction) to wait, if you are being fired upon directly, the safest shot is at the aggressor.
Further:
1. In this case, it would be highly unlikely the defender would know it was a pellet gun, he felt impacts, and we all know due to adrenaline and actual statements from people who have been shot that impacts don't necessarily feel as bad as they may be.
2. Given #1, the choice is effectively to not shoot (and thus high probability you will be shot) or to shoot (low probability of bystander impact due to penetration and then hit, or low-medium probability of bystander impact due to miss).
Given that bystander impacts are a multiple probability event (miss or overpenetration AND bullet hitting a bystander), and the various warning shot angles actually can make things worse (into the air is usually lower angle than required...while straight vertical carries little probability of fatal injury, 20-30deg off vertical in the heat of the moment makes things far far worse, and considering we are arguing over this compared to a heat of the moment miss on CoM of target, must be considered. Also, low angle ground shots, while slowing the bullet, usually result in it fragmenting, increasing the probability of a single impact to a bystander), the shot that has the lowest risk to others is the CoM shot.
Since defense also involves movement so as to also limit the risk to ones self (don't just freeze in place, attempt to find cover and/or spoil attackers shot), moving to create an angle to minimize inadvertent damage is also reasonable.
I hate Monday morning QB'ing DGU's, but in this case, I think its appropriate. Had the aggressor kept shooting if the weapon was drawn, the best shot is the CoM shot. So while it worked out here and the perp stopped w/o the weapon drawn, if I was in the position, I would have drawn, and if the attack didn't stop, gone for the CoM shot.
Some other aspects:
1. The girlfriend acted correctly, obtaining cover. (Smart)
2. The article says "a bystander would have been hit if Mohammed had taken the shot" presumes a chain of events (miss or overpenetration) that can't be stated with the certainty used in the article.
Overall, my logic based on training, reading numerous case studies, and thinking about it a lot, is the safest shot when you feel your life is in danger is into the attacker. In terms of legal results, based on precedent, its easier to have the shoot proved justified (if the requirements have been met, which should be the case if the weapon is even drawn) than to deal with inadvertent impacts on others, and the way to minimize that is not to miss.
Training and practice people, use reactive targets, use multiple targets, practice move and draw, practice rapid target ID.
Take a friend to a range with reactive targets and have them place one of two different color 3x5 cards on a reactive target with you not looking, and before the target turns, have them say the "bad color" (change that up so you don't practice "this color is shoot" by accident) right before the target turns, or use silhouettes of friendly/unfriendly and have them changed without you seeing.
Have an accommodating outdoor range? Practice multiple targets with friendly silhouette targets mixed into the target groups.
Training and practice isn't just accuracy, its shortening your OODA loop.