From cbaaa0cafcac0630c6f07f81663a1b10a4e197a0 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Sat, 15 Sep 2018 16:29:03 -0600 Subject: Change get_inferior_args to return const char * I noticed that get_inferior_args should return const char *, because it is just returning a reference to something owned by the inferior. I'm checking this in. gdb/ChangeLog 2018-09-15 Tom Tromey * infcmd.c (get_inferior_args): Return const char *. * inferior.h (get_inferior_args): Return type now const. * linux-tdep.c (linux_fill_prpsinfo): Update. * procfs.c (procfs_target::make_corefile_notes): Update. --- gdb/linux-tdep.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gdb/linux-tdep.c') diff --git a/gdb/linux-tdep.c b/gdb/linux-tdep.c index 5801ab5..5bfd7ed 100644 --- a/gdb/linux-tdep.c +++ b/gdb/linux-tdep.c @@ -1728,7 +1728,7 @@ linux_fill_prpsinfo (struct elf_internal_linux_prpsinfo *p) char filename[100]; /* The basename of the executable. */ const char *basename; - char *infargs; + const char *infargs; /* Temporary buffer. */ char *tmpstr; /* The valid states of a process, according to the Linux kernel. */ -- cgit v1.1