invalid UTF8 string when i use QJsonDocument::fromJson
<p>In the latest version of Ubuntu, code by qt creator. Qt version is qt 5.41. When I use <code>QJsonDocument :: fromJson</code> create json objects, json object is created successfully. Code is as follows:</p>

<pre><code>#include &lt;QJsonDocument&gt;
#include &lt;QDebug&gt;

int main(int argc,char **argv){
    QString str = "{\"chinese\":\"china 中国\"}";
    QJsonDocument json;
    QJsonParseError error;
    json = QJsonDocument::fromJson(str.toUtf8(),&amp;error);

    qDebug()&lt;&lt;json.toJson();
    //In Rhel5 Result:NULL

    qDebug()&lt;&lt;error.errorString();
     //In Rhel5 Result:invalid UTF8 string"

    str = "{\"english\":\"china english\"}";
    json = QJsonDocument::fromJson(str.toUtf8(),&amp;error);

    qDebug()&lt;&lt;json.toJson();
   //In Rhel5 Result successful : 
  //    {
  //    "english": "china english"
  //     }

   qDebug()&lt;&lt;error.errorString();//In Rhel5 Result:no error occurred""
 return 0;
}
</code></pre>

<p>However, when the exact same code to run on <code>rhel5</code>, I got a description of the error: invalid UTF8 string. On <code>rhel5</code>, compiled <code>qt5</code> library functions, so you can execute programs on qt5 rhel5.</p>

<p>When json string is in English, <code>rhel5</code> run properly, correct json string.</p>

<p>In addition, <code>rhel5</code> support utf-8 encoded.</p>