In Pirates of the Caribbean: At World's End, Liz Swann was taken captive along with her crew members after being made Captain and a Pirate Lord by a dying Sao Feng. A redeemed James Norrington is among those who imprisoned her, but after some soul-searching, he releases them.
Liz is about to escape when Bootstrap Bill tries to stop them. And Norrington says something about 'their destinies have been entwined, but never joined' and faces Bootstrap. Rather than let Liz be re-captured, he shoots the rope she's hanging from, drops her in the sea and gets himself skewered.
He had both his sword and his gun out, and pointing at Bootstrap, but he uses the gun on the rope, and the sword, not at all. He could have just shot Bootstrap, pulled himself onto the rope, then used the sword to cut it. Even if he didn't want to hurt Bootstrap, he could've shot him in the leg or something.
Or he didn't even need to shoot. Climb up to the rope and cut it and follow Liz down. From how Bootstrap was acting, it didn't seem likely he'd have jumped off after them, or had the presence of mind to grab the rope (in which case, just cut it again). And it couldn't be that he couldn't reach the rope: Liz just hopped up and grabbed it, and she's a lot shorter than him.
It was really convenient, I guess, giving Norrington an honourable way to die, to break the love triangle and leave Liz for Will, but still... Did he really mean to get himself killed?