The Habs receive $3.75 million in salary relief with the transaction, according to CapFriendly, giving them more flexibility ahead of the April 12 trade deadline. There's no salary cap in the postseason.
Gallagher suffered the injury while blocking a shot Monday against the Edmonton Oilers.
The pesky 28-year-old winger finishes his season with 14 goals and nine assists in 35 games.
The 2020-21 regular season is projected to wrap up by May 11 - at the earliest - so it's possible Gallagher returns at some point during Round 1 of the playoffs, should Montreal qualify.