The caption on the photo says it was commissioned in Buffalo so it must have sailed through the Welland canal and the locks on the St Lawrence river to get to Montreal.
Interesting transit.