Your husband sounds like a very strong man but maybe he is a little tired of fighting. You needed to say strong words (maybe not those exact ones) to help uplift him at that time and let him know he can't give up. I am sure he knows you love him and want only the best for him.
I have some experience with long-term caregiving. My husband fought colon cancer for six years before he lost his battle. I am glad your husband is still with us, but I can understand how frustrating it is to want him to take better care of himself. Most of us caregivers have said things we could feel guilty about. The woulda, coulda, shouldas often haunt us. You said what you felt you had to say. Hopefully, it will have results. You did the best you could at the time. I'm betting that he is sick and tired of being sick and tired, too.
Now lovingly tell him that you are feeling guilty about what you said. Reopen the lines of communication and talk about ways to improve both of your health. Bet there are things you can do, too. Explain, as well, that your words came from the fear of losing him which I'm guessing is your greatest fear. Then let it go. You can't do it for him. My husband's favorite saying the last few years was, "Let it go; just let it go." Often it was, "Just let it go,dear. just let it go." I still hear that in