Initializes seqDumpPos on qiodevice.cpp
This was spotted by RIM static code checking team. seqDumpPos is a dummy variable which is only used on sequential mode. It is used as a simultaneous storage area of both pPos and pDevicePos when in sequential mode, to keep both in sync. They just suggested that it would be a good practice to initialize the variable, since it does not have any side effect, and there's not much value on not doing it. Change-Id: I8138729eb31df5779c91b368c2cfaecd39788f29 Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Jonas Gastal <jgastal@profusion.mobi>
This commit is contained in:
parent
d5268eabfb
commit
e7e8799304
@ -118,7 +118,7 @@ void debugBinaryString(const char *data, qint64 maxlen)
|
||||
*/
|
||||
QIODevicePrivate::QIODevicePrivate()
|
||||
: openMode(QIODevice::NotOpen), buffer(QIODEVICE_BUFFERSIZE),
|
||||
pos(0), devicePos(0)
|
||||
pos(0), devicePos(0), seqDumpPos(0)
|
||||
, pPos(&pos), pDevicePos(&devicePos)
|
||||
, baseReadLineDataCalled(false)
|
||||
, firstRead(true)
|
||||
@ -562,6 +562,7 @@ void QIODevice::close()
|
||||
d->openMode = NotOpen;
|
||||
d->errorString.clear();
|
||||
d->pos = 0;
|
||||
d->seqDumpPos = 0;
|
||||
d->buffer.clear();
|
||||
d->firstRead = true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user