This.
I would define railroading as the DM forcing specific outcomes because the DM has decided that that specific outcome will happen regardless of any action within the game and that no action taken in the game can change that outcome.
So, a linear adventure isn't a railroad since the DM is not forcing specific outcomes. A dungeon where you have three rooms connected by a single tunnel is not a railroad. No choices are being forced on the players.
@iserith has a really good definition here.
How is a linear adventure not forcing an outcome, though? If you have to go through the wickets, then... well, the game is forced to go through the wickets. You can dress this up, and even hide it (Illusionism is a good term, here), but you're still doing this.
Railroading is the term for the degenerate form of play that "linear adventure" manages to do without the degeneracy. You can structure a linear adventure such that it progresses smoothly -- ie, the players are incentivized and want to go through the next wicket. This becomes a "railroad" when the GM has to force it noticeably. Pretty much any of the WotC adventures is linear in this regard -- you have to go through the wickets. Some, like CoS, hide this well by letting you go through the middle wickets in any order. IE, wickets B, C, and D, are really just Bi, Bii, and Biii. At least one B is required for C. And, this is great! It's actually pretty well done, because it does a good job of incentivizing players to jump through these wickets. It goes sour, though, if the players decide to do something off-script, and the GM forces a wicket on them. That's when "railroading" gets deployed.
"Railroading" is not especially different from quite a lot of fun, entertaining, and frankly common play approaches. It's just the degenerate form of it, where something has gone wrong and the response by the GM is to step on the game to force it. It's not actually a different thing, just a bad version of a quite common approach to play. Now, that said, some people have a strong aversion to that approach to play, and characterize any form of it as the degenerate version. And, the degenerate version can be quite unenjoyable -- badly so -- and so there's a lot of stigma built up about it, so anything close enough for someone to get a whiff gets pounded -- but that's really silly. It's been a predominant approach to D&D and D&D-alikes (most games with high GM prep and the GM centered at the source of most of the fiction) that it's throwing the baby out with the bathwater. It's not the only way to approach these games, not at all, but it's a very common one.