struct procinfo *pi;
{
int ppid;
- struct proc_ctl pctl;
ppid = pi->prstatus.pr_ppid;
{
struct procinfo *pi = (struct procinfo *)
xmalloc (sizeof (struct procinfo));
+#ifdef UNIXWARE
struct sig_ctl sctl;
- struct flt_ctl fctl;
+#endif /* UNIXWARE */
memset ((char *) pi, 0, sizeof (*pi));
if (!open_proc_file (pid, pi, O_RDWR, 1))
int pid;
{
struct procinfo *pi;
- struct sig_ctl sctl;
+#ifdef PROCFS_USE_READ_WRITE
struct flt_ctl fctl;
+#endif
pi = find_procinfo (pid, 1);
if (pi != NULL)
int *statvalp;
{
struct procinfo *temp_pi, *next_pi;
+#if defined (UNIXWARE) || defined (PROCFS_USE_READ_WRITE)
struct proc_ctl pctl;
+#endif
#ifdef UNIXWARE
pctl.cmd = PCRUN;
#ifdef PR_ASYNC
{
long pr_flags;
+#ifdef PROCFS_USE_READ_WRITE
struct proc_ctl pctl;
+#endif
/* Solaris needs this to make procfs treat all threads seperately. Without
this, all threads halt whenever something happens to any thread. Since
int pid;
{
struct procinfo *pi;
- struct sig_ctl sctl;
+#ifdef PROCFS_USE_READ_WRITE
struct flt_ctl fctl;
+#endif
int nlwp, *lwps;
pi = init_procinfo (pid, 0);
pi->was_stopped = 0;
if (1 || query ("Process is currently running, stop it? "))
{
+#ifdef PROCFS_USE_READ_WRITE
long cmd;
+#endif
/* Make it run again when we close it. */
modify_run_on_last_close_flag (pi->ctl_fd, 1);
#ifdef PROCFS_USE_READ_WRITE
if (signal
|| (THE_PR_LWP (pi->prstatus).pr_flags & (PR_STOPPED | PR_ISTOP)))
{
+#ifdef PROCFS_USE_READ_WRITE
long cmd;
- struct proc_ctl pctl;
+#endif
if (signal || !pi->was_stopped ||
query ("Was stopped when attached, make it runnable again? "))
int checkerr = 0;
int rtnval = -1;
struct procinfo *pi;
- struct proc_ctl pctl;
scan_again:
{
struct siginfo newsiginfo;
struct siginfo *sip;
+#if defined (UNIXWARE) || defined (PROCFS_USE_READ_WRITE)
struct sigi_ctl sictl;
+#endif
#ifdef PROCFS_DONT_PIOCSSIG_CURSIG
/* With Alpha OSF/1 procfs, the kernel gets really confused if it
{
int signal_to_pass;
struct procinfo *pi, *procinfo, *next_pi;
+#if defined (UNIXWARE) || defined (PROCFS_USE_READ_WRITE)
struct proc_ctl pctl;
+#endif
pi = find_procinfo (pid == -1 ? inferior_pid : pid, 0);
int nmap;
struct prmap *prmaps;
struct prmap *prmap;
+#ifdef PROCFS_USE_READ_WRITE
struct stat sbuf;
+#endif
if (!summary)
{
long pr_flags;
#endif
int retval = 0;
+#ifdef PROCFS_USE_READ_WRITE
struct proc_ctl pctl;
+#endif
#if defined (PIOCSET) || defined (PCSET) /* New method */
pr_flags = PR_FORK;
long pr_flags;
#endif
int retval = 0;
+#ifdef PROCFS_USE_READ_WRITE
struct proc_ctl pctl;
+#endif
#if defined (PIOCSET) || defined (PCSET) /* New method */
pr_flags = PR_RLC;
{
int lwp_id;
struct procinfo *childpi;
+#ifdef UNIXWARE
struct proc_ctl pctl;
+#endif
/* We've just detected the completion of an lwp_create system call. Now we
need to setup a procinfo struct for this thread, and notify the thread
{
next_pi = pi->next;
if (pi->pid == pid)
- if (procfs_read_status (pi)) /* alive */
- return 1;
- else
- /* defunct (exited) */
- {
- close_proc_file (pi);
- return 0;
- }
+ {
+ if (procfs_read_status (pi)) /* alive */
+ return 1;
+ else
+ /* defunct (exited) */
+ {
+ close_proc_file (pi);
+ return 0;
+ }
+ }
}
return 0;
}