What steps will reproduce the problem?
1. Compile software on 64 bit windows environment
2. Do something to get failed write or read operation
3. Get return value of 0xFFFFFFFF instead of -1
On error QextSerialPort returns (DWORD)-1, which equals to 32 bits set. This
will fail on 64 bit system where that value is a positive (and large) integer.
Error value is returned like this:
qint64 QextSerialPort::writeData(...)
{
...
return (DWORD)-1; // Equal to 4294967295
}
It should be:
qint64 QextSerialPort::writeData(...)
{
...
return -1; // Actually returns -1
}
Attached diff contains a fix for this.
(It also removes two unused variable warnings)
Original issue reported on code.google.com by seppo.ra...@gmail.com on 27 Jan 2011 at 2:36
Original issue reported on code.google.com by
seppo.ra...@gmail.com
on 27 Jan 2011 at 2:36Attachments: