You also don't want years of planning and gameplay to be cut short by a single failure. Unlike in a video game, you can't just restore the last save to try again. When you reach a Bad End, the rest of the story never gets told.
I've been GMing on a regular basis for about a decade now, and I find that if a player or the whole group is about to do something that seems like a terrible idea, it's good to talk to them about what they're trying to accomplish. It may be that there's some sort of miscommunication about the situation; verbal description and human memory are hardly perfect. It may be that they haven't considered all the consequences. (On the other hand, not having the GM's omniscient perspective, there may be no way for them to be aware of the consequences that seem obvious to the GM.) They may just be doing something silly to be funny and entertain the other players; games are supposed to be fun, after all. They might just be fucking around out of boredom or to be a dick. They might think that they can manage to pull off this really unlikely and dangerous thing, and when they do it will be totally awesome. (And they might be right. Tabletop RPGs tend to run on action movie logic, after all.) Or they might have come up with a great idea to solve the problem that the GM didn't anticipate. Just because they're not doing things in the way you expected them to doesn't mean that they're doing things wrong. That's the great advantage tabletop gaming has over video games: the freedom to come up with creative ideas that the game's creators never anticipated. That's why they need a human GM with the flexibility to improvise on the fly to run them.
If any and every mistake were punished with death and campaign failure, everyone would be too afraid of getting smacked down to every try anything creative. Consequences for bad decisions, sure, but not game-ending ones. Probably not even permanent ones unless the players are just absolutely refusing to take a hint or listen. And if they keep making choices that seem intended to derail the campaign, then it's time to ask yourself if the players are here to play your game, or a game of their own devising called "Let's Troll the GM"? And if that's the case, then why are you spending your Saturday night with these people?