Summary: Study at the height of the AIDS death rate found that homosexuality led to shortened lifespan. AIDS death rate has declined dramatically, but there has not been a followup study.
Here's a politifact analysis: https://www.politifact.com/virginia/statements/2012/jun/07/b...
More recently, a 2014 pro-LGBT study claimed to show a shortened lifespan, attributed to prejudice: https://www.medicaldaily.com/can-prejudice-kill-you-lesbian-... though this failed replication ("No effect found") https://www.sciencedirect.com/science/article/pii/S027795361...
I don't argue that obesity isn't bad for you, but the issue is more complex, and I don't think it's right to stigmatize people for it.