mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-14 09:13:08 -07:00
Allow semicolon in json values (Windows paths support)
This commit is contained in:
parent
9c7807ded4
commit
91f9a46c18
1 changed files with 4 additions and 1 deletions
|
@ -114,7 +114,10 @@ QVariantMap json::fromJson(const QString& json) {
|
|||
if (!tmp.isEmpty()) couples << tmp;
|
||||
|
||||
foreach (const QString &couple, couples) {
|
||||
QStringList parts = couple.split(":");
|
||||
QStringList parts;
|
||||
qint32 jsonSep = couple.indexOf(":");
|
||||
parts << couple.mid(0, jsonSep);
|
||||
parts << couple.mid(jsonSep + 1);
|
||||
if (parts.size() != 2) continue;
|
||||
QString key = parts.first();
|
||||
if (key.startsWith("\"") && key.endsWith("\"")) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue