A gene that helps to control inflammation increases the risk of obesity and could be turned off in mice to stop weight gain, a study has found.