Get file position when attaching an open file descriptor to QFile
commit6f52892206b155451e7b24cdbb1b4ab6569153e9
authorJoão Abecasis <joao@abecasis.name>
Tue, 20 Oct 2009 13:39:06 +0000 (20 15:39 +0200)
committerJoão Abecasis <joao@abecasis.name>
Wed, 21 Oct 2009 11:46:08 +0000 (21 13:46 +0200)
treea48982ca819dbc06d07d3dbb40dd00a4578377bb
parentbadfa3435f740ec7120b2ed3367fa2be50382136
Get file position when attaching an open file descriptor to QFile

This was already being done when attaching to FILE* streams. Doing the
same here makes the API consistent and more usable. Namely, one can use
QFile::pos() to obtain the file position.

Test case verifies this doesn't break support for sequential files. More
thorough test case included in large file support test.

Reviewed-by: Thiago Macieira
src/corelib/io/qfile.cpp
tests/auto/qfile/tst_qfile.cpp