microRTPS: templates: check only the major and minor of FastRTPS to set the 'discovery_config' namespace

This commit is contained in:
TSC21
2020-03-24 16:25:29 +00:00
committed by Nuno Marques
parent a13e8e573e
commit 1b453ed849
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -91,7 +91,7 @@ bool @(topic)_Publisher::init()
// Create RTPSParticipant
ParticipantAttributes PParam;
PParam.rtps.builtin.domainId = 0;
@[if version.parse(fastrtps_version) <= version.parse('1.8')]@
@[if version.parse(fastrtps_version[:3]) <= version.parse('1.8')]@
PParam.rtps.builtin.leaseDuration = c_TimeInfinite;
@[else]@
PParam.rtps.builtin.discovery_config.leaseDuration = c_TimeInfinite;