| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
| |
- Some compilers don't like using QPointer in connect(). Use
QPointer::data() instead. This fixes the build for linux SLES 12.
- Enable simplecoapclient example only when Qt is compiled with gui.
Fixes: QTBUG-78884
Change-Id: I592e52eaea93f8f94a2b1af18ea29e745c44dde9
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
- Added more details for explaining the usage of the disconnect()
method.
- Fixed a warning.
Change-Id: Ifa5a91d9df70592009545a467a47c840889ff516
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
| |
After 5d7e221bbf9e27e90448243909abc76d81733381 an assertion will be
triggered when calling QRandomGenerator::bounded with equal low and
high values.
Change-Id: Id6d7c0f583285a54303452a6f2538f3ca72adced
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
| |
|
|
|
|
|
| |
Change-Id: If2376d7d38689001bc93ebd962507b21a05a09f9
Reviewed-by: Karsten Heimrich <karsten.heimrich@qt.io>
|
|
|
|
|
|
|
|
|
| |
Copies of the QObjectData (as a result, also QObjectPrivate)
have been disabled recently. Removed unnecessary copy constructors
of the private classes and their usages.
Change-Id: I15dd766abc88a657a267cbdc95f0c95346a47f72
Reviewed-by: Karsten Heimrich <karsten.heimrich@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
- qcoapprotocol.cpp:387: implicit conversion changes signedness: 'int' to 'uint' (aka 'unsigned int')
- tst_qcoapclient.cpp:365: implicit conversion loses integer precision: 'int' to 'quint16' (aka 'unsigned short')
- tst_qcoapclient.cpp:502: implicit conversion changes signedness: 'int' to 'uint' (aka 'unsigned int')
- tst_qcoapclient.cpp:504: implicit conversion changes signedness: 'int' to 'uint' (aka 'unsigned int')
Change-Id: I5bec42fc69925f04641285c6473d9ddc3ba6ec56
Reviewed-by: Karsten Heimrich <karsten.heimrich@qt.io>
|
|
|
|
|
|
|
| |
Fixed a wrong closing parenthesis location, based on the RFC.
Change-Id: I3aa369a66411bbef1ca6f7b8b8c72fad9281c60c
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
When parsing the CoAP option values, pointers to temporary QByteArray
data were used, which could lead to parsing garbage instead of the
option value. So far this stayed undetected, when compiling with most
of the compilers, except for MSVC.
Change-Id: I4751b514dee008d9186306857f3d6737547f31fb
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
|
|
|
|
|
| |
Change-Id: I8f18562fd543f087bd9d5f4c1d9b3bce7146025e
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
| |
Change-Id: Ie1e6d69895abfb7b63254b41aa738b5708691d09
Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
When sending multiple CoAP messages at once, some of the frames may
wait in the pending frames queue until the transport gets to "Connected"
state. After the state is changed to "Connected", we need to send all
pending frames, instead of sending only one frame.
Change-Id: I7d22f6018894881bb5c074202c4ad235d72a1fea
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
|
|
| |
As a result of the recent refactoring, the security mode was being
ignored when crating 'observe' requests. Added the missing parameter.
Change-Id: Ib24d68c6794700164274ef66e48aa758918f6c91
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: Ifcef69e73ea89f30499063452920dd9abb446f7e
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
For security reasons it is recommended to use tokens with a length of
at least 4 bytes. Added a method for setting the minimum token size and
changed it to be 4 by default.
Change-Id: Ib589b338df8e59ccaf24dceab6691f92d92f861c
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: I5b51c71ab11cbce5755a69c58f34bfa5e7cd5385
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
| |
Instead of using #ifdefs for the private class tests, conditionally
enable/disable subprojects for them.
Change-Id: I574dc34dd895a4fc2eeb311dfb91a149a6715e28
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
| |
This change is based on the feedback from API review.
Change-Id: I422f08cfc31d442893feefcacfa34271e8d7954b
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
| |
This change is based on the feedback from API review.
Change-Id: Ia17d061c60fcf7aa4da38542d96d75ae621f657a
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
- Rename QCoapPrivateKey::isEmpty() -> QCoapPrivateKey::isNull().
- Use 'preSharedKeyIdentity' instead of 'identity'.
This change is based on the feedback from API review.
Change-Id: Iba517a01a16edede86c4572204d560978b3dc067
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
- The RFC specifies the following option formats: empty, opaque, uint
and string. Leave only the construcors for the specified types.
- Rename value getters to reflect the expected value type.
- Move the internally used setter methods to the private class.
This change is based on the feedback from API review.
Change-Id: I0b482770b9c02e64b0f345384ebf58ec29a7e9bc
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
Replies are created internally, and pointers to created objects are
returned to the user. Users should not be able to create instances of
QCoapReply or QCoapResourceDiscoveryReply.
This change is based on the feedback from API review.
Change-Id: Ibd59c62fd19c4b312253d4c4621b195bf5816340
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Moved internally used methods to the private class.
- Replaced the internally used protected constructor with a static
method in the private class.
- Removed the internally used setMethod(), no need for it anymore.
- Removed the isValid() method, no point in keeping it.
This change is based on the feedback from API review.
Change-Id: I177efdb1d436266549dea3e8d2b01160648fce90
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Rename QCoapMessage::MessageType -> QCoapMessage::Type
- Rename option() -> optionAt()
- Rename removeAllOptions() -> clearOptions()
- Hide findOption(). option() is more convenient to use instead.
- Add a setOptions() method.
This change is based on the feedback from API review.
Change-Id: I2093a06ca09eebb95865a82e09d2aa2265379e5d
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
| |
This change is based on the feedback from API review.
Change-Id: I189b2505c64ba01f6a6294853a12074a0035585a
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
| |
This change is based on the feedback from API review.
Change-Id: I43f08d5bd7f7f172ea4d337718be7bd14e81d64c
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
| |
Additionally rename responseCodeError() -> errorForResponseCode().
This change is based on the feedback from API review.
Change-Id: Ida63a854f628d3d92a93bd54bd80f2368de48d8d
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
| |
This change is based on the feedback from API review.
Change-Id: I345bc519d6753608ead0bf4b006cf68c4e52c313
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
| |
This change is based on the feedback from API review.
Change-Id: I99f00d15e9474b2844a436113ac7771ead7b33c6
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
| |
No need to keep this class public, there is no public API for accessing
it anyway.
Change-Id: I231a560becb5799667819c30eca6372282adeb41
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
At the moment only the QCoapQUdpConnection class implements the
QCoapConnection interface. If later we decide to add other
implementations, and it turns out that the current API is not good
enough, it won't be possible to change it without breaking the source
compatibility. Let's make these classes private, we can make them public
when there is a need for it.
Change-Id: I41336dda0e6eaa762f0eb9c8f4aa98a9c7b62a2c
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
QtCoap::Error is a scoped enum class, so its value names will get the
"Error::" prefix anyway. No need to have it as a suffix for the value
names.
For the same reason replaced QtCoap::Error::NoError by
QtCoap::Error::Ok.
Change-Id: Iaf7b51cdab6ea330e940e5af73ba93a55eb48315
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
Execptions are made for QCoapOption::OptionName and QtCoap::Port enums,
because the values of these types are not limited only to the values
listed in the enums. In case of using custom values, it would be more
convenient to use integers directly, instead of using a static_cast each
time the user needs a custom value.
Change-Id: Ibc63e26c59629702c03528dd7e5e5eedc6bcc90a
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: Ibf19500b897c0d2eb3a9ab9420ee98b04074b20a
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: I8bc64842a2d0ed70fc40a5ae4492cb4b2a3611b8
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
|
|
|
|
|
|
|
|
| |
This class is intended for internal use only, so it should not have a
public header.
Change-Id: I18f2433d06e978582b470e14dc89a7c0e404f7d4
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: I32f3712ed2c160e1dc26397d58114fa441c0fc9b
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
|
| |
This method doesn't need to be virtual, no one overrides it.
Change-Id: Ia8c06c40fcb7cb97e413da6dc0458553540803cf
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: Ifb15180619c1d7e056a5578c30d22e2e9e16edd5
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
|
|
|
|
|
|
| |
Change-Id: I916ddb226b653aaf563ecf0adc3a1110d6da3132
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
|
|
|
|
|
|
|
| |
Change-Id: I1ebf03d68c267f87ca2b690d4c666c26717f8d07
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
| |
Change-Id: I4f193b0d65bb3104db6483749cf9dc36547e1861
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: Icc21315a5a20eeee02b578dc56459d4697a6361d
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
|
|
| |
This example demonstrates sending secure CoAP GET requests
in PreSharedKey and Certificate modes.
Change-Id: I90ea8c77232bfca1ca86bdd7a73223b6ba8b0c9b
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: If210c040ec40a828d4c997251ef2a635e2e70d32
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
QUrl can have an empty host, but still considered to be valid.
This is possible, for example, when setting an invalid host address or
when the URL is a path. Adjusting such URLs leads to unexpected results.
Added a check for preventing sending requests to URLs with no host.
Fixes: QTBUG-75155
Change-Id: I6c899f824233f32cddb8c9255fd3d1c333bb6385
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: I565cd306ab36230371cde6475d8417b40752a2a5
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
|
|
|
|
|
| |
Change-Id: I066acf1d2765f4c48392371e50f86f694c1af7bc
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
| |
Change-Id: Iebded58e8cfd307cd54fc3bdcca3a1002aa21bd4
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|