Apple has fixed a glitch that caused iPhones registered in China to crash when they received a message with an emoji showing the Taiwanese flag.
Devices have reportedly been crashing since the icon was blocked in 2017, an apparent attempt at censorship because the Chinese government refuses to acknowledge Taiwan's independence.
Security researcher Patrick Wardle told Wired that the flaw was a censorship function made by Apple that occasionally read the Taiwan emoji as an "invalid input", causing the app it was sent over to shut down.
Mr Wardle informed Apple about the bug and helped the company to fix it, which Apple noted in a security update in June and fixed on Tuesday.
Mr Wardle said: “If Apple had never tried to appease the Chinese government, the bug would never have been introduced in the first place.”
This is not the first time that the US company has made diplomatic changes to its devices for China.
Apple have previously moved Chinese users' data to servers within the country, as well as removed some VPNs from the App Store in China.
Apple have been contacted for comment.