/* The find command.
- Copyright (C) 2008-2016 Free Software Foundation, Inc.
+ Copyright (C) 2008-2017 Free Software Foundation, Inc.
This file is part of GDB.
#include "value.h"
#include "target.h"
#include "cli/cli-utils.h"
+#include <algorithm>
/* Copied from bfd_put_bits. */
}
}
- s = skip_spaces_const (s);
+ s = skip_spaces (s);
}
/* Get the search range. */
if (*s == ',')
++s;
- s = skip_spaces_const (s);
+ s = skip_spaces (s);
if (*s == '+')
{
struct type *t;
ULONGEST pattern_buf_size_need;
- s = skip_spaces_const (s);
+ s = skip_spaces (s);
v = parse_to_comma_and_eval (&s);
t = value_type (v);
/* Keep it simple and assume size == 'g' when watching for when we
need to grow the pattern buf. */
pattern_buf_size_need = (pattern_buf_end - pattern_buf
- + max (TYPE_LENGTH (t), sizeof (int64_t)));
+ + std::max (TYPE_LENGTH (t),
+ (unsigned) sizeof (int64_t)));
if (pattern_buf_size_need > pattern_buf_size)
{
size_t current_offset = pattern_buf_end - pattern_buf;
if (*s == ',')
++s;
- s = skip_spaces_const (s);
+ s = skip_spaces (s);
}
if (pattern_buf_end == pattern_buf)
do_cleanups (old_cleanups);
}
-/* Provide a prototype to silence -Wmissing-prototypes. */
-extern initialize_file_ftype _initialize_mem_search;
-
void
_initialize_mem_search (void)
{