The Escapist
(2008)

The whole prison break is a delusion of Frank (Brian Cox) while he's dying from a stab wound.

He learned of his daughter's death the day before and having no more reason to get out, he stayed behind to buy the others some time.

In the end, the others begin their escape as previously seen but without Frank.

Thanks Fleetwood!