aboutsummaryrefslogtreecommitdiff
path: root/gdb/fbsd-nat.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/fbsd-nat.c')
-rw-r--r--gdb/fbsd-nat.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/gdb/fbsd-nat.c b/gdb/fbsd-nat.c
index 71a8386..3a4bd55 100644
--- a/gdb/fbsd-nat.c
+++ b/gdb/fbsd-nat.c
@@ -188,7 +188,7 @@ fbsd_nat_target::find_memory_regions (find_memory_region_ftype func,
Pass MODIFIED as true, we do not know the real modification state. */
func (kve->kve_start, size, kve->kve_protection & KVME_PROT_READ,
kve->kve_protection & KVME_PROT_WRITE,
- kve->kve_protection & KVME_PROT_EXEC, 1, false, data);
+ kve->kve_protection & KVME_PROT_EXEC, true, false, data);
}
return 0;
}
@@ -304,7 +304,7 @@ fbsd_nat_target::info_proc (const char *args, enum info_proc_what what)
if (pid == 0)
error (_("No current process: you must name one."));
}
- else if (built_argv.count () == 1 && isdigit (built_argv[0][0]))
+ else if (built_argv.count () == 1 && c_isdigit (built_argv[0][0]))
pid = strtol (built_argv[0], NULL, 10);
else
error (_("Invalid arguments."));
@@ -1203,7 +1203,7 @@ fbsd_nat_target::resume_one_process (ptid_t ptid, int step,
return;
}
- for (thread_info *tp : inf->non_exited_threads ())
+ for (thread_info &tp : inf->non_exited_threads ())
{
/* If ptid is a specific LWP, suspend all other LWPs in the
process, otherwise resume all LWPs in the process.. */
@@ -1887,7 +1887,7 @@ fbsd_nat_target::detach_fork_children (inferior *inf)
{
/* Detach any child processes associated with pending fork events in
threads belonging to this process. */
- for (thread_info *tp : inf->non_exited_threads ())
+ for (thread_info &tp : inf->non_exited_threads ())
detach_fork_children (tp);
/* Unwind state associated with any pending events. Reset
@@ -2465,14 +2465,12 @@ fbsd_nat_get_siginfo (ptid_t ptid, siginfo_t *siginfo)
if (ptrace (PT_LWPINFO, pid, (caddr_t) &pl, sizeof pl) == -1)
return false;
if (!(pl.pl_flags & PL_FLAG_SI))
- return false;;
+ return false;
*siginfo = pl.pl_siginfo;
return (true);
}
-void _initialize_fbsd_nat ();
-void
-_initialize_fbsd_nat ()
+INIT_GDB_FILE (fbsd_nat)
{
add_setshow_boolean_cmd ("fbsd-lwp", class_maintenance,
&debug_fbsd_lwp, _("\