aboutsummaryrefslogtreecommitdiff
path: root/gdb/procfs.c
diff options
context:
space:
mode:
authorStu Grossman <grossman@cygnus>1993-10-16 22:32:04 +0000
committerStu Grossman <grossman@cygnus>1993-10-16 22:32:04 +0000
commit952a820e43deb9f8c794bbd3d8349fdaddfed2da (patch)
treec6a355d501a105d5c4631906d3947440dbecc4e8 /gdb/procfs.c
parent0aede9635509eaa0f84d2daa129aa965d5ba6f61 (diff)
downloadgdb-952a820e43deb9f8c794bbd3d8349fdaddfed2da.zip
gdb-952a820e43deb9f8c794bbd3d8349fdaddfed2da.tar.gz
gdb-952a820e43deb9f8c794bbd3d8349fdaddfed2da.tar.bz2
* procfs.c (procfs_set_sproc_trap): Don't use this if sproc
isn't available. * (procfs_notice_signals): Fix prototype.
Diffstat (limited to 'gdb/procfs.c')
-rw-r--r--gdb/procfs.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/gdb/procfs.c b/gdb/procfs.c
index 04b3ae2..fb5970d 100644
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -427,7 +427,7 @@ static void
procfs_create_inferior PARAMS ((char *, char *, char **));
static void
-procfs_notice_signals PARAMS ((pid_t pid));
+procfs_notice_signals PARAMS ((int pid));
static struct procinfo *
find_procinfo PARAMS ((pid_t pid, int okfail));
@@ -1474,7 +1474,7 @@ GLOBAL FUNCTION
SYNOPSIS
- static void procfs_notice_signals (pid_t pid);
+ static void procfs_notice_signals (int pid);
DESCRIPTION
@@ -1493,7 +1493,7 @@ DESCRIPTION
static void
procfs_notice_signals (pid)
- pid_t pid;
+ int pid;
{
int signo;
struct procinfo *pi;
@@ -3371,6 +3371,8 @@ DESCRIPTION
so that any grand-children start with all tracing flags set.
*/
+#ifdef SYS_sproc
+
static void
procfs_set_sproc_trap (pi)
struct procinfo *pi;
@@ -3383,9 +3385,7 @@ procfs_set_sproc_trap (pi)
error ("PIOCGEXIT failed");
}
-#ifdef SYS_sproc
praddset (&exitset, SYS_sproc);
-#endif
if (ioctl (pi->fd, PIOCSEXIT, &exitset) < 0)
{
@@ -3408,6 +3408,7 @@ procfs_set_sproc_trap (pi)
#endif
#endif
}
+#endif /* SYS_sproc */
/* Fork an inferior process, and start debugging it with /proc. */
@@ -3424,7 +3425,9 @@ procfs_create_inferior (exec_file, allargs, env)
/* Setup traps on exit from sproc() */
- procfs_set_sproc_trap(current_procinfo);
+#ifdef SYS_sproc
+ procfs_set_sproc_trap (current_procinfo);
+#endif
proceed ((CORE_ADDR) -1, 0, 0);
}