summaryrefslogtreecommitdiff
path: root/gdb/target.c
diff options
context:
space:
mode:
authorLuis Machado <luisgpm@br.ibm.com>2013-09-03 17:22:44 +0000
committerLuis Machado <luisgpm@br.ibm.com>2013-09-03 17:22:44 +0000
commit36a31ec983a162960eb0c14d1054f8cb95a5db87 (patch)
treefbb07ee5aa17dc2b3550c96ad6bd8fd8f0051b05 /gdb/target.c
parent365ca53d7124553b08c9ff6d1120f06e42c1f552 (diff)
downloadgdb-36a31ec983a162960eb0c14d1054f8cb95a5db87.tar.gz
* inf-child.c (inf_child_follow_fork) New parameter
detach_fork. * inf-ptrace.c (inf_ptrace_follow_fork): Likewise. * inf-ttrace.c (inf_ttrace_follow_fork): Likewise. * inferior.h (detach_fork): Remove. * infrun.c (detach_fork): Adjust comment and make it static. (follow_fork): Pass detach_fork parameter to target_follow_fork. * linux-nat.c (linux_child_follow_fork): New parameter detach_fork. * target.c (target_follow_fork): New parameter detach_fork. Pass detach_fork as parameter and print its value. * target.h (struct target_ops) <to_follow_fork>: New int parameter. (target_follow_fork): New parameter detach_fork.
Diffstat (limited to 'gdb/target.c')
-rw-r--r--gdb/target.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/gdb/target.c b/gdb/target.c
index 3659bb90e4f..d55712d4c1c 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -2811,7 +2811,7 @@ target_program_signals (int numsigs, unsigned char *program_signals)
follow forks. */
int
-target_follow_fork (int follow_child)
+target_follow_fork (int follow_child, int detach_fork)
{
struct target_ops *t;
@@ -2819,11 +2819,12 @@ target_follow_fork (int follow_child)
{
if (t->to_follow_fork != NULL)
{
- int retval = t->to_follow_fork (t, follow_child);
+ int retval = t->to_follow_fork (t, follow_child, detach_fork);
if (targetdebug)
- fprintf_unfiltered (gdb_stdlog, "target_follow_fork (%d) = %d\n",
- follow_child, retval);
+ fprintf_unfiltered (gdb_stdlog,
+ "target_follow_fork (%d, %d) = %d\n",
+ follow_child, detach_fork, retval);
return retval;
}
}