Skip to content

Commit

Permalink
Add parameter in dds templete to allow 'ros_discovery_info' topic
Browse files Browse the repository at this point in the history
Signed-off-by: Ivan Santiago Paunovic <[email protected]>
  • Loading branch information
ivanpauno committed Mar 16, 2020
1 parent 0b873ad commit 8bf8974
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions sros2/sros2/policy/templates/dds/permissions.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
</domains>
</xsl:variable>

<xsl:param name="allow_ros_discovery_topic" select="0"/>

<xsl:template match="/policy/contexts">
<xsl:variable name="dds">
<dds xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
Expand Down Expand Up @@ -57,6 +59,21 @@
</xsl:for-each>
</allow_rule>
</xsl:if>
<xsl:if test="$allow_ros_discovery_topic">
<allow_rule>
<xsl:copy-of select="$template_domains"/>
<publish>
<topics>
<topic>ros_discovery_info</topic>
</topics>
</publish>
<subscribe>
<topics>
<topic>ros_discovery_info</topic>
</topics>
</subscribe>
</allow_rule>
</xsl:if>
<default>DENY</default>
</grant>
</xsl:for-each>
Expand Down

0 comments on commit 8bf8974

Please sign in to comment.