aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/gdbsupport/common-utils.h5
2 files changed, 7 insertions, 3 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index d8e3fe1..7c737ac 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2019-10-19 Simon Marchi <simon.marchi@polymtl.ca>
+
+ * gdbsupport/common-utils.h (startswith): Change return type to
+ bool.
+
2019-10-19 Christian Biesinger <cbiesinger@google.com>
* bcache.c (bcache::print_statistics): Use std::sort instead of qsort.
diff --git a/gdb/gdbsupport/common-utils.h b/gdb/gdbsupport/common-utils.h
index a5312cb..e96fc21 100644
--- a/gdb/gdbsupport/common-utils.h
+++ b/gdb/gdbsupport/common-utils.h
@@ -110,10 +110,9 @@ std::string extract_string_maybe_quoted (const char **arg);
extern char *safe_strerror (int);
-/* Return non-zero if the start of STRING matches PATTERN, zero
- otherwise. */
+/* Return true if the start of STRING matches PATTERN, false otherwise. */
-static inline int
+static inline bool
startswith (const char *string, const char *pattern)
{
return strncmp (string, pattern, strlen (pattern)) == 0;