Well, it is a well known fact that diabetics whose blood sugar is not controlled well are more likely to have various infections. Other than the immune system being wonkers, this also could be because of the high blood sugar as well...food for bacteria to thrive on. Another thing is, it is known that the more you exercise, the more NK cells you are likely to have.
So, as well as some direct effect of changed metabolism because of obesity, there could be other subtle factors contributing. (Okay, I am not an immunologist, so I am getting off this soap box before I dig a hole for myself.

)