Fastfood company McDonald's has withdrawn a commercial which some consumers in China found insulting, according to the Xinhua news agency.