It does indeed look like some sort of prolapse or hernia.
I'm afraid there isn't anything you can do, apart from keep the water in tip top condition (so, plenty of extra water changes) and keep your fingers crossed. Fish are remarkably resilient and it may be able to pull through.