diff options
author | Tom Tromey <tom@tromey.com> | 2021-10-25 18:20:24 -0600 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2021-12-12 10:56:38 -0700 |
commit | abb6af934c54e386c2bca8d725a496f239a9bac2 (patch) | |
tree | a3e838775742acfc3ebc044c7aec6018f8370943 /gdb/source.h | |
parent | 2749ac133972d027fe9482acc81f6e88c4f36812 (diff) | |
download | gdb-abb6af934c54e386c2bca8d725a496f239a9bac2.zip gdb-abb6af934c54e386c2bca8d725a496f239a9bac2.tar.gz gdb-abb6af934c54e386c2bca8d725a496f239a9bac2.tar.bz2 |
C++-ify path substitution code
I found some uses of xfree in the path substitution code in source.c.
C++-ifying struct substitute_path_rule both simplifies the code and
removes manual memory management.
Regression tested on x86-64 Fedora 34.
Diffstat (limited to 'gdb/source.h')
-rw-r--r-- | gdb/source.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/source.h b/gdb/source.h index 2b9e8f3..e146ce9 100644 --- a/gdb/source.h +++ b/gdb/source.h @@ -128,7 +128,7 @@ extern symtab_and_line set_current_source_symtab_and_line extern void clear_current_source_symtab_and_line (void); /* Add a source path substitution rule. */ -extern void add_substitute_path_rule (char *, char *); +extern void add_substitute_path_rule (const char *, const char *); /* Flags passed as 4th argument to print_source_lines. */ enum print_source_lines_flag |