-Wwrite-strings: Constify shell_escape and plug make_command leak
authorPedro Alves <palves@redhat.com>
Wed, 5 Apr 2017 18:21:34 +0000 (19:21 +0100)
committerPedro Alves <palves@redhat.com>
Wed, 5 Apr 2017 18:21:34 +0000 (19:21 +0100)
commitbe47f9e8180d7275b0e2b26998472e99be9a2d7b
treedd8f61a069e65b93b2fea5a56cf7693593aac80f
parentbde6261aed330cd8d108c387bfe659a6171525dd
-Wwrite-strings: Constify shell_escape and plug make_command leak

gdb/ChangeLog:
2017-04-05  Pedro Alves  <palves@redhat.com>

* cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
(shell_command): New function.
(make_command): Use std::string.
(init_cli_cmds): Register shell_command instead of shell_escape.
gdb/ChangeLog
gdb/cli/cli-cmds.c