It would heavily depend on when they served, much as with any army.
The Legionnaires at Cannae and Trasimene didn’t fare too well.
If they got in a tight spot, which mostly happened during civil wars, facing their own kind, it could get hairy, but defeated forces in the civil wars knew when to call it quits and generally were not wrong to expect decent treatment.
When Caesar defeated Pompey at Pharsalus, Caesar pursued his fleeing adversary with one of Pompey's own legions under his command. They arrived in Alexandria and at some point Caesar sent about half of them back to Rome. That was the force he used to knock the ever-lovin' crap out of the numerically superior Greco-Egyptian army of Ptolemy the last.