Either it stops being profitable because we stop using its product and civilization survives, or it stops being profitable because we stop using its product because civilization collapses. Either way, the long term outlook isn't good.
Oil is a wonderful resource with many uses that will remain valuable long after we stop relying on fossil fuels; it forms the basis for most of chemical industry from plastics to pharmaceuticals. It's just that currently it's so extremely cheap and abundant that we simply burn most of it.
I don't think the latter is true. Crude oil is still a great source of fuel and even in the worst case society collapse people will still need fire.
That's making the rather bold assumption that the climate will be habitable for humankind.
I can see a potential future where we destroy the environment so badly we decide to permanently live indoors with artificial atmosphere, yet we still burn oil outdoors...
That's the case for every corporation ever!
This could essentially be said about any corporation.