Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use shell=False in when launching gazebo #1385

Merged
merged 1 commit into from
May 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions gazebo_ros/launch/gzclient.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@


def generate_launch_description():
cmd = [[
cmd = [
'gzclient',
_boolean_command('version'), ' ',
_boolean_command('verbose'), ' ',
_boolean_command('help'), ' ',
LaunchConfiguration('extra_gazebo_args'),
]]
]

model, plugin, media = GazeboRosPaths.get_paths()

Expand Down Expand Up @@ -99,7 +99,7 @@ def generate_launch_description():
cmd=cmd,
output='screen',
additional_env=env,
shell=True,
shell=False,
prefix=prefix,
on_exit=Shutdown(),
condition=IfCondition(LaunchConfiguration('gui_required')),
Expand All @@ -110,7 +110,7 @@ def generate_launch_description():
cmd=cmd,
output='screen',
additional_env=env,
shell=True,
shell=False,
prefix=prefix,
condition=UnlessCondition(LaunchConfiguration('gui_required')),
),
Expand Down
7 changes: 4 additions & 3 deletions gazebo_ros/launch/gzserver.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ def generate_launch_description():
cmd=cmd,
output='screen',
additional_env=env,
shell=True,
shell=False,
prefix=prefix,
on_exit=Shutdown(),
condition=IfCondition(LaunchConfiguration('server_required')),
Expand All @@ -196,7 +196,7 @@ def generate_launch_description():
cmd=cmd,
output='screen',
additional_env=env,
shell=True,
shell=False,
prefix=prefix,
condition=UnlessCondition(LaunchConfiguration('server_required')),
),
Expand All @@ -219,6 +219,7 @@ def _arg_command(arg):

# Add gazebo_ros plugins if true
def _plugin_command(arg):
cmd = ['"-s libgazebo_ros_', arg, '.so" if "true" == "', LaunchConfiguration(arg), '" else ""']
cmd = ['"-s', 'libgazebo_ros_', arg, '.so" if "true" == "',
LaunchConfiguration(arg), '" else ""']
py_cmd = PythonExpression(cmd)
return py_cmd