As far as conflict goes, it takes a lot of ingenuity to create a situation in which everyone is happy, especially in the case of a negative consequence like death. Naturally, no one wants their own hand-crafted character to die as a result of having flaws, or making mistakes. Still, it is your job as a GM to ensure that an outcome is decided and that the story continues smoothly, enjoyably, and fairly.
I heard of plenty of ways to avoid displeasing multiple persons with the outcome of a conflict. Some involve "beginner's luck" or some other form of reduced consequences, and some require a lot of out-of-the-box thinking. I have no experience leading a roleplay as a GM, considering my free time is spontaneous and scattered, however these are ideas I have heard from friends of mine who have done so in the past.
1: The simplest way to resolve a situation in which a character could die is to reduce consequences and end the conflict prematurely. My friend claimed that this was the simplest way to resolve conflict only because the conflict immediately ends, and everyone has a reason to continue afterwards. This may be the simplest way to resolve conflict, but it is also the most cliche, as you'll see in my example. I suppose you should use this strategy for a situation in which the roleplay would otherwise end.
For instance, if three players, all fighters, are surrounded by five armed bandits and you determine that the players should lose the fight after plenty of turns. Instead of having the vicious bandits outright kill them and end the roleplay, you can have the bandits injure the three players enough to incapacitate them and rob them. The players can then wake up in a nearby town or village, being tended too by a merchant's wife or what not.
The players now have a reason to continue the roleplay: get stronger, and take revenge!
2: When multiple players are in a situation where one or more character must die according to all rules and logic, it is impossible to reduce the consequences of the situation. This is not the end of the line, however, there are two things you can do to keep everyone happy: you can change or add to the rules, or you can alter the situation. Either way, be careful how you do so, because you should neither alter the rules nor the situation enough that the players lose their ability to make decisions - you want to alter the players' decisions.
Take, for example, a situation where two characters are in magical combat. One character has disabled the other from using any magical powers and is casting an ultimate spell which cannot miss and will kill the other as a result of his/her defenselessness. In such a situation, you can alter the situation by having some sort of beast, attracted to the caster due to his/her use of magic, run out from a hiding place and attack the caster. He/she then has to choose between killing his opponent, or killing the beast, which is more of a threat.
This provides a pause which lets the player who would have died the ability to escape, continue fighting, or attempt to negotiate with the other.
On the other hand, take another example. Two magicians are locked in combat once again, this time, one of the magicians trips and drops his or her wand. The one who trips was casting a protection spell the moment before, but cannot use the spell anymore because he/she does not have the wand. The other player attacks the magician at the moment he or she trips, and as a result, the tripped magician should die. You can change the rules in this situation to give the falling magician an exceptionally costly rule exception - the magician can use a weak form of that spell without his or her wand. Instead of dying, the magician gets a second chance.
You can alter the rules however you see fit - maybe the magician gets a giant scar across his hand as a result of channeling magic through it instead of a wand, or maybe the magician loses his ability to use magic permanently. The conflict does not even need to end there, the injured mage has a chance to negotiate, fight, or run away. The point is that you have introduced a new rule which prolonged the roleplay. Just make sure all the characters are okay with the change beforehand, especially in this case, where you change something specifically about a character.
3: Talk. It is rather simple, just talk to the players and ask them what they think should happen. If an attacking player does not actually want his/her character to use a lethal move, then you just resolved the issue by telling the player the situation, because the player will probably edit his/her post. Sometimes, you can form compromises between two characters, such as in the example below. Roleplaying is heavily based on socializing, so I did not think much of this when my friend told it to me, but if I was leading a story along, I suppose I would forget that fairly quickly.
Three characters are helping each other to chant a forbidden ritual to raise an undead warlord. Unfortunately, something goes horribly wrong and, according to the rules of forbidden chanting, one of the characters must die. Unlike magic, there is no way to stop the evil energy of the warlord from killing one of the characters. However, unlike magic, the spiritual energy which kills the player can also be channeled, less lethally, into the other two characters. The third character dies, but becomes a ghost which only the other two characters can see, a ghost which can use the evil warlord's energy to affect the real world.
Clearly, no one wants to die. But in this situation, even though one of the characters had to die, he is still able to play in the game due to a compromise made between the characters. The two others get a consequence, having killed their friend and now having to live, haunted by his ghost, while the third still gets to take part in the roleplay.
That is all I can bring to the table. I, personally, found these three ideas fairly good. There are more, but some of them did not sound quite right, and I have not encountered any situations in which they would work, so I'll leave them out. The whole point is that you do not want to just kick someone out of your roleplay, you want to use your creative thinking to keep everyone involved and interested. Thoughts? Did I misinterpret what my friends said?