diff options
author | Andreas Kling <andreas.kling@nokia.com> | 2010-07-09 14:59:04 (GMT) |
---|---|---|
committer | Andreas Kling <andreas.kling@nokia.com> | 2010-07-09 14:59:04 (GMT) |
commit | bd287865d2b57395a340e85f1fac9b7ddff3ec14 (patch) | |
tree | b35a6e587dcac3e9ca3512c596e3ebc9b4dd0c87 /src/corelib | |
parent | 63171ddd8ec99d9af17e0adcc2cad61586fed42b (diff) | |
download | Qt-bd287865d2b57395a340e85f1fac9b7ddff3ec14.zip Qt-bd287865d2b57395a340e85f1fac9b7ddff3ec14.tar.gz Qt-bd287865d2b57395a340e85f1fac9b7ddff3ec14.tar.bz2 |
QIODPLB: Sync behavior of ungetBlock() and ungetChar()
ungetChar() supports ungetting data that didn't originate from the
QIODevicePrivateLinearBuffer, so ungetBlock() should too.
Diffstat (limited to 'src/corelib')
-rw-r--r-- | src/corelib/io/qiodevice_p.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/io/qiodevice_p.h b/src/corelib/io/qiodevice_p.h index 4a25562..1dd51ea 100644 --- a/src/corelib/io/qiodevice_p.h +++ b/src/corelib/io/qiodevice_p.h @@ -155,10 +155,10 @@ public: if ((first - buf) < size) { // underflow, the existing valid data needs to move to the end of the (potentially bigger) buffer makeSpace(len + size, freeSpaceAtStart); - memcpy(first - size, block, size); } first -= size; len += size; + memcpy(first, block, size); } private: |