MONTREAL - Via Rail and its major union announced early Saturday that they have managed to avert a strike.

The passenger railway and the Canadian Auto Workers union say they reached a tentative agreement ahead of Sunday's midnight strike deadline.

Via spokesman Malcom Andrews said the three-year deal covers such issues as wages, benefits, work conditions and work rules.

"The negotiations were pretty close to around the clock for several days in succession,'' he said, adding both Via and CAW representatives "worked very hard, worked really professionally and really hammered things out.''

Paul Cote, Via's CEO and president, said in a statement that the settlement is good news for Canadian rail passengers.

"VIA is very pleased with the outcome of negotiations. We believe that the settlement is good for our employees, and that it will assure the stability of our operations for the next three years,'' he said in a statement.

The railway and the union will not release any details of the deal until it's ratified. Union leaders will be in Montreal on Monday to begin reviewing the deal.

The union said in a statement that it believes "this is an excellent agreement on behalf of their members and unanimously recommends the ratification of this agreement.''

The CAW represents 2,600 Via Rail workers across Canada, supplying on-board services, ticket agents and skilled trades.

The company and the union had disagreed on wages and benefits.

The union had been without a collective agreement since it expired in December 2006. The two parties have been negotiating with the help of two federal conciliators for several weeks.