diff options
author | Anton Lundin <glance@acc.umu.se> | 2015-09-29 21:12:54 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-09-29 17:46:08 -0400 |
commit | 65e9991501fc810497e102ab66bd8dd438cebcdc (patch) | |
tree | 01a568a2d54baadf669d910412b5130406a6af88 | |
parent | edac07554c50a693389e4d88a6d6f56820c940f1 (diff) | |
download | subsurface-65e9991501fc810497e102ab66bd8dd438cebcdc.tar.gz |
qtserialbluetooth: Remove no-op calls
waitForReadyRead and waitForBytesWritten not overridden in
QBluetoothSocket and the default implementation in QIODevice are just
no-ops that always return false.
This removes those calls to lessen the confusion for anyone who looks at
the code.
Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r-- | qtserialbluetooth.cpp | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/qtserialbluetooth.cpp b/qtserialbluetooth.cpp index 6f93d8cab..6a3360c7d 100644 --- a/qtserialbluetooth.cpp +++ b/qtserialbluetooth.cpp @@ -236,8 +236,6 @@ static int qt_serial_read(serial_t *device, void* data, unsigned int size) while(nbytes < size && device->socket->state() == QBluetoothSocket::ConnectedState) { - device->socket->waitForReadyRead(device->timeout); - rc = device->socket->read((char *) data + nbytes, size - nbytes); if (rc < 0) { @@ -295,8 +293,6 @@ static int qt_serial_write(serial_t *device, const void* data, unsigned int size while(nbytes < size && device->socket->state() == QBluetoothSocket::ConnectedState) { - device->socket->waitForBytesWritten(device->timeout); - rc = device->socket->write((char *) data + nbytes, size - nbytes); if (rc < 0) { |