Top points if you can recognise the game that the picture (to the left) is from. While you're figuring it out, onto the article's premise. Cultivating a decent default ending. Firstly, it's funny how divisive the idea of a pre-planned ending can be and how different games tend to have different rates of accepting it.
Pathfinder and D&D Dungeon Masters and players tend to be more accepting. You're meant to take note of the players' actions and allow them to go off the path but people acknowledge that the sheer amount of preparation time involved in mapping, monster building, NPC character sheets, loot builds, and other such odds and ends means that straying off the path completely can lead to a premature session end unless the Dungeon Master was given advanced notice by the players' actions in earlier sessions.
True, the players expect to be able to change *how* they confront the threat but they're generally willing to accept that the threat's location and responses are likely to be well-established. I think this is also why those occasions when they truly re-write the ending by luring the lich out of its hidey hole or talking down the ogre becomes all the more memorable.
In investigative games like Call of Cthulhu people's opinions on pre-set endings are more mixed. You're expected to have a default ending (as the enemy is meant to have their own plans) and a horror format allows some gentle nudging towards a certain conclusion (i.e. fight the cultists AS they're summoning the byakhee and not beforehand) but you're meant to play fair and if they change the entire ending than that's an acceptable option. After all, the enemies don't have to be painstakingly folded into locations, traps, and supporting enemies. You can even re-use old sheets.
In storytelling games like World of Darkness people can be quite against the idea of pre-set endings. This is probably because its designed to be a sandbox game and so character choices are meant to really matter. Your choices define you and they should define your experience. Also, enemies are arguably easier to create than in many other systems and you don't have to read up on Darkness rules and the effects of terrain beforehand. Since it's easier to wing it, the players won't be so forgiving of any form of rail roading - no matter how gentle.
Now that we've gotten a bit of a background, let's break it down. I'm going to use the term 'pre-set ending' to refer to cases where the ending is inviolate and unchangeable and 'default ending' to refer to cases when the ending is subject to change but the Game Master still has an option up her sleeve that ties into what came beforehand.
Is a 'pre-set ending' somehow immoral? No. It's a tool and like any tool it can be used well. Having complete control of the ending allows you to tell the tale in a way that fully links to the beginning as well as the story themes and provides a sort of message for the players. It generally should be kept for adventures that have as their backbone a very moving story that is best told in a particular manner.
If the players HAVE to sacrifice one of their own into the machinery to slow down an enemy that they HAVE to fight with fire that may set the hospital alight, then that is just fine if you're telling a tale of tragedy and misery. However, is there any reason why the players HAVE to walk right up to the lich in a dungeon crawl without taking advantage of stealth, freed prisoners, and rigged cave ins?
Bear in mind that its easier to pull off a pre-set ending in a one shot adventure as the players have less time to exert their influence and it gets a little illogical if their multiple attempts to change the course of the game fail. Also remember that any constraints on their actions in the ending must be based on realistic in-game constraints. If the players manage to surmount those in-game constraints then, well, let them. Making the world inconsistent will just make your ending jarring and silly anyway.
If the freed prisoners are too frightened to help than a paladin's speech and Aura of Courage SHOULD shore up their will. If they're level 1 Commoners (and always have been - players can tell when you shift the world just to say no to them) then they won't be much help in a distraction and using them will likely just get them killed. If the players are okay with using a crowd of prisoners as a meat shield and manage to bully or cajole them into doing it then let them. Yes, it won't give you the heroic ending you were after but if the party are keen on that angle then you weren't going to get that anyway. Heroism based on the inability to be evil isn't heroism at all.
Perhaps you want to use a pre-set ending because you are in love with that idea and it was the inspiration for the entire adventure. This can be risky as it can tempt you to keep it even when it no longer makes sense. On the other hand, it could truly be a cool idea that your players will enjoy. You could always get player buy-in but once they're roleplaying their characters they might drift off the path. Your best bet is to start with the Ending. You want to explore the cool, crazy factor of a sinking ship? Don't let the characters get a whiff of the sabotage plot until after the ship is sinking. That way you get your exciting adventure premise sooner and they don't feel railroaded.
Now onto 'Decent Default Endings' these are just endings that you have up your sleeve in case the players don't come up with another option and just take the predictable path. It keeps you from being left on the spot when they head into the villain's lair. It gives you a rough gauge on what the bad guys are doing and how far along they are likely to be. It also gives you a chance to come up with something that is cinematic and in line with the players' experiences thus far.
If you're worried that you might fall in love with a 'Default Ending' despite the label then push yourself to create three plausible endings that are equally viable. This is often a good idea, anyway, as it can keep the players from getting stuck if they don't make a leap of logic to figure out your idea nor are sufficiently imaginative / logical to come up with a reasonable alternative. One of the big dangers of investigative or occult adventures, particularly during a sandbox game, is that if you don't think about how it could be solved or the threat dealt with than it might well become an unsolvable plot. Resist the urge to make any of them the Bad Ending (unless its a horror game where Bad Endings can be the best). You can always bear it in mind but try to have multiple Good Endings.
Creating a decent default ending often involves looking at the threat's goals or it's nature and the characters' abilities and interests as well as the likely reactions and behaviours. Then stick the label 'default' on it, write it down and accept that something not used never existed ... and thus can be used later.
Hope this helps you somewhat.
The main Endings article (and all the various links) can be found over here.