diff options
author | Pedro Alves <palves@redhat.com> | 2019-03-06 18:29:17 +0000 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2019-03-06 18:29:17 +0000 |
commit | 72f31aea9e6c158f442239abedaf351465ebcb41 (patch) | |
tree | 3e1eba1360246c8281c7c01e57395cde79343e0a /gdb/linux-fork.h | |
parent | efbecbc143f19cb308ae220fb386505f41ff4bc3 (diff) | |
download | fsf-binutils-gdb-72f31aea9e6c158f442239abedaf351465ebcb41.zip fsf-binutils-gdb-72f31aea9e6c158f442239abedaf351465ebcb41.tar.gz fsf-binutils-gdb-72f31aea9e6c158f442239abedaf351465ebcb41.tar.bz2 |
Make "checkpoint" not rely on inferior_ptid
Don't rely on "inferior_ptid" deep within add_fork. In the
multi-target branch, I'm forcing inferior_ptid to null_ptid early in
infrun event handling to make sure we don't inadvertently rely on the
current thread/target when we shouldn't, and that caught some bad or
unnecessary assumptions throughout.
gdb/ChangeLog:
2019-03-06 Pedro Alves <palves@redhat.com>
* linux-fork.c (new_fork): New, split out of ...
(add_fork): ... this. Return void. Move "first fork" special
case from here, to ...
(checkpoint_command): ... here.
* linux-linux.h (add_fork): Return void.
Diffstat (limited to 'gdb/linux-fork.h')
-rw-r--r-- | gdb/linux-fork.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/linux-fork.h b/gdb/linux-fork.h index e6f1304..f918bcb 100644 --- a/gdb/linux-fork.h +++ b/gdb/linux-fork.h @@ -21,7 +21,7 @@ #define LINUX_FORK_H struct fork_info; -extern struct fork_info *add_fork (pid_t); +extern void add_fork (pid_t); extern struct fork_info *find_fork_pid (pid_t); extern void linux_fork_killall (void); extern void linux_fork_mourn_inferior (void); |