diff options
author | Thiago Macieira <thiago.macieira@intel.com> | 2013-06-07 18:58:11 -0700 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-06-08 05:06:52 +0200 |
commit | 53388cd8e0451ea375ed250b59f9e89319fb3e1c (patch) | |
tree | 8e32ee016804eb4d4cc354fdea8b581369efcb66 | |
parent | 736a052d93d9c75e51e8f3da733bc8e4a50c39ce (diff) |
QUrl stringprep: avoid recalculating the surrogates we already know
Change-Id: Icac4e81fff6f7f7fa4f46ec2a08105f8d3d2b403
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
-rw-r--r-- | src/corelib/io/qurlidna.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/corelib/io/qurlidna.cpp b/src/corelib/io/qurlidna.cpp index fa0a229f4f..b41ad9033d 100644 --- a/src/corelib/io/qurlidna.cpp +++ b/src/corelib/io/qurlidna.cpp @@ -2066,8 +2066,8 @@ Q_AUTOTEST_EXPORT void qt_nameprep(QString *source, int from) if (uc <= 0xFFFF) { *out++ = *in; } else { - *out++ = QChar::highSurrogate(uc); - *out++ = QChar::lowSurrogate(uc); + *out++ = in[-1]; + *out++ = in[0]; } } } |