Bottom line; If a black bear attacks you in camp at night you have no choice but to fight or get eaten. Whether you succeed or not is secondary.
A couple was attacked by a black bear who got the man down and proceed to devour him. The woman attacked the bear, hitting it with her purse, It ran off. The man survived but was never quite the same afterwards..... Some things were missing. Any pepper spray, guns, or large knives will be confiscated by national park rangers if seen. Keep them concealed as well as possible.