aboutsummaryrefslogtreecommitdiff
path: root/gdb/utils.h
diff options
context:
space:
mode:
authorPedro Alves <palves@redhat.com>2017-04-05 19:21:34 +0100
committerPedro Alves <palves@redhat.com>2017-04-05 19:21:34 +0100
commit69bbf465237819bd7bf2a21a682d695273b3c8cb (patch)
tree3850a83c0de5799d95dd93a61bcbf38fca934407 /gdb/utils.h
parentbe47f9e8180d7275b0e2b26998472e99be9a2d7b (diff)
-Wwrite-strings: Constify warning_pre_print
-Wwrite-strings flags a warning here: char *warning_pre_print = "\nwarning: "; gdb/ChangeLog: 2017-04-05 Pedro Alves <palves@redhat.com> * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage the memory of the temporary warning_pre_print override. * utils.c (warning_pre_print): Constify. * utils.h (warning_pre_print): Constify.
Diffstat (limited to 'gdb/utils.h')
-rw-r--r--gdb/utils.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/utils.h b/gdb/utils.h
index fb75f2e97c..2380bd7121 100644
--- a/gdb/utils.h
+++ b/gdb/utils.h
@@ -298,7 +298,7 @@ extern void (*deprecated_error_begin_hook) (void);
/* Message to be printed before the warning message, when a warning occurs. */
-extern char *warning_pre_print;
+extern const char *warning_pre_print;
extern void error_stream (const string_file &) ATTRIBUTE_NORETURN;