| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
This reverts commit 85ee2c658a45d2958a54045951d236769640337f.
That commit completely breaks the I/O on Windows.
Task-number: QTBUG-78086
Change-Id: I9125967d6cb5b1cb4e33d0bad80ee66322e5ccc7
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
|
|\ |
|
| |\
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
.qmake.conf
Change-Id: I5ce880f305ebb0af7f7803769cecf2c899bede12
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When using the waitXXX functions in a loop, many _q_notify signals are
emitted. They are connection via Qt::QueuedConnection, but the event
loop never gets the chance to process them.
Introduce a counter to count the attempts to send a notification, but
only send it once.
Fixes: QTBUG-74961
Change-Id: I0ee4522db63844bdd37169d3a31bde2d6f92f383
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|/ /
| |
| |
| |
| |
| | |
Task-number: QTBUG-74391
Change-Id: I5a468676a2dd9dd44aa80d39a614b06acb0aed81
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
|
|\|
| |
| |
| | |
Change-Id: I3d5718006e8fee8fa3c2f97aec03183a4db1aa7c
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The 'gadget' serial devices have no parent nodes and were skipped from
enumeration. We need to check the names of these devices against the
'ttyGS' prefix and then add matching devices to the enumeration.
[ChangeLog] Fixed enumeration of 'Gadget' (/dev/ttyGS*) serial devices
on Linux.
Change-Id: I88afd80358153795152c1b2c929ca5bfb3adbabb
Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|\|
| |
| |
| | |
Change-Id: I3931aca16393acc9c698dcf018801e1d031004bc
|
| |
| |
| |
| |
| | |
Change-Id: I9cf8c41c4fb37728154bc0cd74124a549b00e3ff
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
|
|\|
| |
| |
| | |
Change-Id: I35bc56c0e1bc2efa96c86c7a0a33322e72a4fdd9
|
| |
| |
| |
| |
| |
| | |
Change-Id: Ie4f4239368e292cfbd7e36456c7c1d638d404077
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
|
|/
|
|
|
|
|
|
|
|
| |
It is not allowed to include files within Qt namespace.
See 5b99f3a3 in qtbase dev.
Change-Id: I21af750ef73dfe3c1191c1e8cc843c3235be3c19
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Liang Qi <liang.qi@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Fixes numerous warnings:
unknown pragma ignored [-Wunknown-pragmas]
when compiling with clang-cl.
Task-number: QTBUG-63512
Change-Id: Idba2ab207d6512e3930ee467b98d4dc73b8aeb25
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit d57b9e83857253a1479f89fca18ea5856db39fb7 introduced
a regression, where the QSP may ignore all the read events when
the data comes to the device within opening. In this case, even
re-opening of a device does not help.
Reason is that the QWinOverlappedIoNotifier is enabled after than
the startAsyncCommunication() called, that probably, leads to
ignoring for all EV_RXCHAR events. A workaround is to enable the
notifier before than any of I/O operation called.
Task-number: QTBUG-67224
Change-Id: I21538fddc4dfd850c600e1d74f3c393a59a00549
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Following code snippet:
QSerialPort serial("/dev/ttyUSB0");
serial.open(QIODevice::WriteOnly);
serial.write("ABCDEF");
serial.waitForBytesWritten(-1);
causes an application crash if some of data will be received by the
serial port.
Reason is that qt_poll_msecs() triggered with POLLIN event, even if the
device is opened with O_WRONLY flag. In this case the readNotification()
handler is called, which trying to reserve some space from the
uninitialized read QRingBuffer, that causes an assertion.
Solution is to don't use the POLLIN event if device is open with
O_WRONLY flag.
Change-Id: I205be31608359f52b5ef286a33dd266ed11a2649
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
|
|\
| |
| |
| |
| |
| |
| | |
Conflicts:
.qmake.conf
Change-Id: Icf5a1d17d2a9ea612449f2fdbf6903892cbed411
|
| |
| |
| |
| |
| |
| |
| |
| | |
old header.LGPL21 was used in some src files.Replace ones in src/ with
correct header.LGPL one. Also remove unnecessary license files.
Change-Id: I1d752c8361b8b23fcd3232818553da60bbdabfca
Reviewed-by: Liang Qi <liang.qi@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| | |
As QWinOverlappedIoNotifierPrivate is not documented, replace
the /*! ... */ comment with a standard C-style comment.
Change-Id: I813e62503214fc686b913ccd770fb6e35922baa9
Reviewed-by: Martin Smith <martin.smith@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| | |
QDoc requires the function body to follow immediately after the
/*! ... */ comment.
Change-Id: I385bdfe16003e29950352a83ddb13fe75badcc5f
Reviewed-by: Martin Smith <martin.smith@qt.io>
|
|\|
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
examples/serialport/blockingmaster/masterthread.h
examples/serialport/blockingslave/slavethread.h
Change-Id: I6b6bf25b41ff0f1b0b9632069d3b13f6c47c6421
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The examples were already adopted to use <QSerialPort> instead
<QtSerialPort/QtSerialPort>.
Change-Id: Id9d3b0b04f31ac3d32554aa34941696903511577
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| |\
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
.qmake.conf
examples/serialport/blockingmaster/masterthread.cpp
Change-Id: I3716089bae99247f98ed02656d4418de5f866c1d
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
[ChangeLog][QSerialPort] Added a note to the documentation that
waitForReadyRead() and waitForBytesWritten() never time out if
the parameter msecs is -1.
Change-Id: I5852da14faf1bba5a338db6a8764da582238aae7
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Qt includes should be added before platform-specific includes.
Change-Id: Ie8bcf306c9e0f3d5d719ee57bcddc8bd2967f5cb
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
It makes sense to use the
QStandardPaths::writableLocation(QStandardPaths::TempLocation)
directory for any of Unix-like platforms, as a 'last resort'
to store the lock-files, if no other preferable directory
was found.
Change-Id: Ifd1a5789c014388509b29837171d3fdc440d63e6
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | | |
Change-Id: I844f5102077e7b4d5240947a614bfb163c8b7890
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
|
| | |
| | |
| | |
| | |
| | |
| | | |
Change-Id: I12da9eb3a57fc312fb4b029714166af10755ca76
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
|
| | |
| | |
| | |
| | |
| | |
| | | |
Change-Id: I427b993a3a71f199029a8956cdf0dc2c98f0e444
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
|
|/ /
| |
| |
| |
| |
| | |
Change-Id: Ia7491b477bac319a8e0ee1a3e20778c8078edb15
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| |
| |
| |
| |
| | |
Change-Id: Ib57b52598e2f452985e9fffd1459eb18587c99e3
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
|
|\|
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
.qmake.conf
src/serialport/qserialport_win.cpp
Change-Id: Icc832e218a1135cb82e780ccaa63abd990289eaf
|
| |
| |
| |
| |
| |
| |
| |
| | |
'bytesToRead' takes the result of signed 64-bit computation which could
be negative. So, its type should be qint64.
Change-Id: Ib51129143fcb70475ad383df417ae4282c858e41
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| | |
This patch replicates commit 225ef1baeb0e49f157f3ba1271915e623bd27dd9
for Windows.
Change-Id: Ic4e3444183289e7ce1a487500633fb5ad95590b9
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If the user calls setReadBufferSize() with a value lesser than the
current size of the read buffer, then we get UB in readNotification():
readFromPort(nullptr, some_negative_value);
Change-Id: Iddf5838c84c8615670285e9883c48f29faacc07e
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We should not add the size of the internal write buffer here because
QIODevice::bytesToWrite() already checks it. Also, take into account
the size of 'writeChunkBuffer' on Windows.
Change-Id: I87dfcb4dd1cd9d2bbb6f82a084d79fb4db9323d8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
|
| |
| |
| |
| |
| |
| |
| | |
... as this function is implemented in cpp file.
Change-Id: Ia5a0c262ebdb4b98b4575c85ab45fdc93742731f
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
|
| |\
| | |
| | |
| | | |
Change-Id: Ib336529542ae9b78937ad1573fde71ccfcc4c1ad
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The limitations were introduced by the commit 56c001b, but were not
documented.
Change-Id: I5e44ab78e2e5cce2477ebc1f83280fa8c22e0ef6
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
... as there are plans to remove it from the QtCore.
Change-Id: I79a2250b7b392896fa1c7307488a74dd44d62736
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Read notifications should be enabled all the time while the device is
opened unless the buffer size limit is reached. To enable the read
notifier again, the user needs to read the data or enlarge the buffer
with a setReadBufferSize() call.
According to that scenario, it's very likely that the device will
toggle the state of notifier twice (on->off->on) in one notification
cycle. This patch prevents this unnecessary toggling by:
- unconditionally setting the notifier's state in setReadBufferSize()/
readData();
- deferring the notification disabling in readNotification() on Unix
and in completeAsyncRead() on Windows to the next notification
cycle.
Change-Id: I97fc041bb705c034a7e73d1437e64b9b34dc2c18
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This reduces the number of syscalls and thus the CPU load when dealing
with fast ports. And 32KiB seems still small enough to be no concern on
modern hardware even if it's excessive for a given port.
Change-Id: I4749e4255627d3abf2393323216e01ac6436413b
Reviewed-by: Alex Trotsenko <alex1973tr@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
We do not need to use the ifdef guards for the CBR_ constants,
because constants are standard and always exists in native API.
Change-Id: I75ae9ffc17b132786fe5e72791b3f7c82c72c76e
Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
... otherwise, this notifier's instance will be active even
if the serial port is not open.
Change-Id: Ieebb894a048f3ed89ac5d1c259e21bc790f5d387
Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The event mask variable is used only once in process of initialization,
so we do not need to keep this variable as the class member.
Change-Id: I1f97a312cc92345d435dee821fefb8c2de33665e
Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
| | |
| | |
| | |
| | |
| | |
| | | |
Change-Id: Ia9b0851ea7259bc4bc1aa709992b5eb215144a77
Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|/ /
| |
| |
| |
| |
| | |
Change-Id: I0dc20fa836888d3caa678fd8f5b620625e00ec92
Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|/
|
|
|
| |
Change-Id: I77f015100f2b9ed5e1a16ebd1ba0b28216282085
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
| |
... where has been added the '\c' tag where it is required.
Change-Id: Ie346fc147deb535501eb365693a2ff5fe22a98f9
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
|
|
|
| |
qserialport.cpp: In member function 'void QSerialPort::setSettingsRestoredOnClose(bool)':
qserialport.cpp:627:9: warning: 'void QSerialPort::settingsRestoredOnCloseChanged(bool)' is deprecated [-Wdeprecated-declarations]
Change-Id: I4ed17403cd1692c4f965a69be711f0c5b03a8376
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|\
| |
| |
| | |
Change-Id: Ia83609bd366762621857a6c63bf935a6cd230742
|