Details
-
Bug
-
Resolution: Duplicate
-
P3: Somewhat important
-
4.4.3
-
None
Description
QDataStream has code like
dev->write(b, 2);
which doesn't check that the write was successful.
If the disk is full, then the above might not write 2 bytes, but 0 or 1.
QDataStream needs error checking in order to be useful (in a robust manner).
It would be as simple as:
if (dev->write(b,2) < 2)
q_status = CouldNotWrite;
(which would be a new enum value for the Status enum).