summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRitt Konstantin <ritt.ks@gmail.com>2009-08-21 12:52:09 (GMT)
committerJoerg Bornemann <joerg.bornemann@trolltech.com>2009-08-21 13:10:32 (GMT)
commit4209fa5809f5a0a8de2a346c56a0640cc15193ee (patch)
treebce0e62563d7fff5714c1a2b36de2cb657185521 /src
parent48758257c77ab6698e8f11b1d7acfdaa93158054 (diff)
downloadQt-4209fa5809f5a0a8de2a346c56a0640cc15193ee.zip
Qt-4209fa5809f5a0a8de2a346c56a0640cc15193ee.tar.gz
Qt-4209fa5809f5a0a8de2a346c56a0640cc15193ee.tar.bz2
QFile: unset errorString as well as error
Prefer using unsetError() since it unsets both error and errorString. Merge-request: 833 Reviewed-by: Joerg Bornemann <joerg.bornemann@trolltech.com>
Diffstat (limited to 'src')
-rw-r--r--src/corelib/io/qfile.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/corelib/io/qfile.cpp b/src/corelib/io/qfile.cpp
index daadad7..ab45bf7 100644
--- a/src/corelib/io/qfile.cpp
+++ b/src/corelib/io/qfile.cpp
@@ -1467,7 +1467,7 @@ bool QFile::seek(qint64 off)
d->setError(err, fileEngine()->errorString());
return false;
}
- d->error = NoError;
+ unsetError();
return true;
}
@@ -1495,7 +1495,7 @@ qint64 QFile::readLineData(char *data, qint64 maxlen)
qint64 QFile::readData(char *data, qint64 len)
{
Q_D(QFile);
- d->error = NoError;
+ unsetError();
if (!d->ensureFlushed())
return -1;
@@ -1577,7 +1577,7 @@ qint64
QFile::writeData(const char *data, qint64 len)
{
Q_D(QFile);
- d->error = NoError;
+ unsetError();
d->lastWasWrite = true;
bool buffered = !(d->openMode & Unbuffered);