In my iPhone app, the application receives its data from a server in XML format and displays it in UILabel. The data coming from the server may contain £ sign. This sign is not encoded in any way – just passed as is in the XML string. The app takes this string and displays it in a UILabel.
This works just fine most of the times. It always works fine in a simulator, including iOS 5.1, however one of the users reported a bug indicating that instead of display the £, the UILabel actually shows £ – which is most bizzare.
The UILabel text is set with this simple line of code:
contentLabel.text = [node getValueForKey:keyName];
I have stepped through the code with debugger and can see that the correct string value is being passed and set. I can also see correct results on the simulator.
However (as can be seen from the image below) something going amiss on this user’s phone. Is there something I am missing? What could be the problem here? And, more importantly, how can I solve this? The things are complicated by the fact that everything works fine on my phone and simulator and this user is across the country from me, so I can’t get physical access to their phone.
Here’s the screenshot from the simulator:

And here’s the screenshot from the affected user’s phone:

The problem seems to have solved itself on its own. I couldn’t reproduce it on either iOS 4 or iOS 5, nor could several other users I spoke with. Upon checking with the user who initially reported the problem, she said that after upgrading iOS from 5.1 to 5.1.1, the problem went away. Oh well… 🙂