Sometimes the most little thing can be devil.
Webmasters: you have all experienced that day with encoding hell where there’s something wrong between php/ database/ browser. Especially if you’re working with foreign multibytes languages (mais o%? sont encore pass%#es mes accents fran%@ais).
It can be quite frustrating. But when you add Visual Studio + Ogre + UTF8 code points in the loop… that might be the worst day of your life.
Anyway good news: I’ve now found where my flying pointer was coming from.