Jeroen Koekkoek
ac020f62f7
Add read-write locks for POSIX
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-30 23:32:26 +01:00
eboasson
69f563be5b
Merge pull request #60 from FirasSahliADLinktech/multiple_tests
...
Some missing unit tests and correct signature
2018-11-30 12:07:44 +01:00
Firas Sahli
6908e3deea
Correct signature and add tests for dds_instance_get_key
...
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-11-28 10:52:14 +01:00
Firas Sahli
8aa6ceff81
Add test for dds_qos_copy and extra check to dds_qset_partition
...
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-11-28 10:41:24 +01:00
Firas Sahli
4b627fd9aa
Add simple test for dds_time
...
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-11-28 10:38:07 +01:00
Erik Boasson
68f2ce9724
Update getting started guide to use new QoS function names
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-11-27 15:28:20 +01:00
Erik Boasson
ec68eeac29
Bring listener operations naming scheme in line with the rest
...
The main naming scheme is OPER_TYPE (i.e., dds_create_participant) but the listener operations were named TYPE_OPER (i.e., dds_listener_create). This commit brings the listener scheme in line with the rest, retaining the old names as a deprecated interface.
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-11-09 14:18:51 +01:00
Erik Boasson
651bdfee06
Bring QoS operations naming scheme in line with the rest
...
The main naming scheme is OPER_TYPE (i.e., dds_create_participant) but the QoS operations were named TYPE_OPER (i.e., dds_qos_create). This commit brings the QoS scheme in line with the rest, retaining the old names as a deprecated interface.
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-11-09 14:18:47 +01:00
Erik Boasson
a519d9f597
Eliminate some "possible misuse of comma operator" warnings
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-11-09 12:33:22 +01:00
eboasson
2e2224daea
Merge pull request #31 from eboasson/builtintopics
...
Refactor sample representation (along with a few small other details)
2018-11-09 12:23:47 +01:00
eboasson
970680468c
Merge pull request #34 from k0ekk0ek/cunit
...
Cleanup and CUnit integration and add support for theories and fixtures
2018-11-08 17:31:16 +01:00
Jeroen Koekkoek
f56eccf6a6
Fix exit codes returned by CUnit test runner
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-08 11:51:54 +01:00
Jeroen Koekkoek
217def362c
Fix location of generated header for CUnit based tests
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-08 09:42:14 +01:00
Jeroen Koekkoek
c903fee0c9
Extend strcasecmp tests and convert them to theories
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-08 09:42:02 +01:00
Jeroen Koekkoek
94722a642e
Make cast from CU_ErrorCode to int in CUnit test runner main explicit
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-08 09:41:57 +01:00
Jeroen Koekkoek
6171d44b62
Add -Wno-missing-field-initializers to COMPILE_FLAGS property on test source files
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-08 09:41:42 +01:00
Erik Boasson
263a9b30a3
Do not consider loopback on Windows multicast-capable
...
Tests with network interface set to 127.0.0.1 don't see any multicasts
despite multicast loopback being enabled. It therefore seems the
multicast flag on the loopback interface on Windows is at least
unreliable, and so the safest course of action is to disable multicast
by default on that interface.
Internal/AssumeMulticastCapable can still be used to override this and
enable multicasting anyway.
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-11-06 09:32:28 +01:00
Erik Boasson
8ba218dca8
dissociate WSAEvent from sockets handled on dedicated threads
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-11-05 16:00:41 +01:00
Erik Boasson
d05b0a4d13
Use GetSystemTimePreciseAsFileTime
...
When building for Windows 8 or later, use
GetSystemTimePreciseAsFileTime, otherwise do a run-time lookup of that
function and fall back to GetSystemTimeAsFileTime if it doesn't exist.
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-11-05 08:56:20 +01:00
Jeroen Koekkoek
599bf311cf
Fix Windows issues with CUnit fixture initialization
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-02 14:37:43 +01:00
Jeroen Koekkoek
ecaf72c003
Fix test registration on macOS
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-02 13:27:15 +01:00
Jeroen Koekkoek
630178fb12
Cleanup CUnit integration and add support for theories
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-01 19:32:24 +01:00
Erik Boasson
4a4f4e22d1
dds_stream_extract_key: reserve space in destination before calling dds_stream_read_fixed_buffer
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 21:37:06 +08:00
Erik Boasson
e3874c3c27
add some missing details in comments for serdata operations
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 21:04:26 +08:00
Erik Boasson
b34cbdcf0c
sockaddr_compare should really be ipaddr_compare
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 13:38:16 +08:00
Erik Boasson
f2f436bde3
wrap indirect calls to WHC in inline functions
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 13:28:19 +08:00
Erik Boasson
3e343d032a
reduce dependency on sertopic->status_cb_entity
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 13:26:24 +08:00
Erik Boasson
7cb80e7851
minor refactor of CDR-to-key/keyhash generation
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 13:24:07 +08:00
Erik Boasson
259e4676dc
fix sequencing of internal liveliness monitoring and rtps init/term
...
liveliness monitoring requires rtps stack initialised if initially deaf, so starting the monitoring thread must happen after rtps_init
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-28 13:54:17 +08:00
Erik Boasson
9cab5e769c
various interconnected changes for ddsi_serdata
...
- topic-erased key-only serdata for use in tkmap
- restoration of including key values in invalid samples
- special handling of keyless topics
- keyhash generation via streams
- elimination of dynamically allocated buffers in keyhash
- removal of the last vestiges of "serstate"
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-28 13:31:23 +08:00
Erik Boasson
8e20ae547e
avoid declaring an array on stack with non-constant size
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-26 20:34:35 +08:00
Erik Boasson
fd931a2605
remove accidental return statement on the return of a void function
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-26 20:32:47 +08:00
Erik Boasson
e841e4bf94
add back in the broken filter and query condition support
...
the implementation was and is terrible, but without it too many tests fail
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-26 20:05:18 +08:00
Erik Boasson
791a0efe7e
replace some implementation dependent types in protocol message specifications
...
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-26 16:26:30 +08:00
Erik Boasson
a25f683bcf
abstract the internal representation of a sample
...
besides the old state being in dire need of cleaning up, this also paves the way for having any number of different sample representations in the system
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-26 16:25:26 +08:00
Jeroen Koekkoek
8fc9535316
Terminate address filter with OS_AF_NULL instead of 0 (AF_UNSPEC)
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-24 22:32:27 +02:00
Jeroen Koekkoek
40b7b5f423
Copy socket address regardless of interface state
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-24 19:33:51 +02:00
Jeroen Koekkoek
4b3c6ed643
Fix warning caused by assert on parameter required to be nonnull
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-24 16:53:12 +02:00
Jeroen Koekkoek
961706bb48
Replace NULL address family filter by supported address families
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-24 16:31:43 +02:00
Jeroen Koekkoek
25198e565b
Rename os_sockaddr_size to os_sockaddr_get_size for consitency
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-24 15:53:29 +02:00
Jeroen Koekkoek
0324f36dd2
Disable IPv6 interface tests if IPv6 is not available at runtime
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-24 00:13:16 +02:00
Jeroen Koekkoek
fbde1ba5b8
Do not stop interface iteration if address is NULL
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-19 17:50:13 +02:00
Jeroen Koekkoek
a9e160ec07
Update API documentation for modified socket address functions
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-19 17:35:08 +02:00
Jeroen Koekkoek
6b41dada9d
Fix compiler warnings
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-19 17:35:08 +02:00
Jeroen Koekkoek
6867f949cd
Add extra os_getifaddrs test cases
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-19 17:35:08 +02:00
Jeroen Koekkoek
03c081fa18
Simplify os_getifaddrs operation for POSIX platforms
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-19 17:30:33 +02:00
Jeroen Koekkoek
7ba3bca087
Change socket function signatures to use os_sockaddr
...
* Consolidated and cleaned up some (duplicate) functions.
* Removed some unused functions that did not make sense to keep around.
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-19 17:00:15 +02:00
Jeroen Koekkoek
ea3f5e7ff4
Disable AF_PACKET interfaces for all platforms but Linux
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-19 16:58:40 +02:00
Jeroen Koekkoek
458b1df3f7
Replace os_sockQueryInterfaces by os_getifaddrs
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-19 16:58:40 +02:00
Jeroen Koekkoek
2fc4cac1a7
Consolidate some duplicate functions
...
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-10-19 16:58:40 +02:00