I was told to only consider handguns that generate muzzle energy in excess of 2,500 joules for bear defence, especially when you've just been woken up.
.45 ACP: 500j-900j.
10mm Auto: 500j-1000j.
.357 Magnum: 700j-1100j.
.44 Magnum: 1000j-2000j.
.50 AE: 1,600j-2,200j.
.454 Casull: 2,300j-2,800j
.460 S&W: 2,700j-3,900j
.500 S&W: 3,400j-4,200j
.600 Nitro Express: 11,000j
.700 Nitro Express: 12,100j.
If you're being actively attacked by a bear or are just woken up on an adrenaline rush, your group size will go to s**t and it will become a matter of dumping your ammunition into your target. An American friend said he put five rounds of .500 S&W into a bear in less than three seconds. He doubted it survived the first shot but when you're scared for your life you don't exactly pay attention to the damage done to your attacker.
Take your pick, the last two are not serious suggestions though.