2004-01-07 Michael Chastain <mec.gnu@mindspring.com>
[deliverable/binutils-gdb.git] / gdb / proc-api.c
index a74882db7e2e50cbc92f21a615757b0762d88234..1e4a2dccf170e9a6f605c5805341cb3958176eae 100644 (file)
@@ -1,5 +1,7 @@
 /* Machine independent support for SVR4 /proc (process file system) for GDB.
-   Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
+
+   Copyright 1999, 2000, 2001, 2003 Free Software Foundation, Inc.
+
    Written by Michael Snyder at Cygnus Solutions.
    Based on work by Fred Fish, Stu Grossman, Geoff Noer, and others.
 
@@ -43,7 +45,7 @@ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #include <sys/user.h>  /* for struct user */
 #endif
 #include <fcntl.h>     /* for O_RDWR etc. */
-#include <sys/wait.h>
+#include "gdb_wait.h"
 
 #include "proc-utils.h"
 
@@ -423,7 +425,7 @@ static struct trans rw_table[] = {
   { PCSEXIT,  "PCSEXIT",  "set traced syscall exit  set" },
   { PCSFAULT, "PCSFAULT", "set traced fault set" },
   { PCSFPREG, "PCSFPREG", "set floating point registers" },
-#ifdef PCHOLD                  /* solaris */
+#ifdef PCSHOLD                 /* solaris */
   { PCSHOLD,  "PCSHOLD",  "set signal mask" },
 #endif
   { PCSREG,   "PCSREG",   "set general registers" },
@@ -572,16 +574,6 @@ write_with_trace (int fd, void *varg, size_t len, char *file, int line)
        break;
       default:
        {
-#ifdef BREAKPOINT
-         static unsigned char break_insn[] = BREAKPOINT;
-
-         if (len == sizeof (break_insn) &&
-             memcmp (arg, &break_insn, len) == 0)
-           fprintf (procfs_file ? procfs_file : stdout, 
-                    "write (<breakpoint at 0x%08lx>) \n", 
-                    (unsigned long) lseek_offset);
-         else 
-#endif
          if (rw_table[i].name)
            fprintf (procfs_file ? procfs_file : stdout, 
                     "write (%s) %s\n", 
@@ -755,7 +747,7 @@ procfs_note (char *msg, char *file, int line)
       if (info_verbose)
        fprintf (procfs_file ? procfs_file : stdout, 
                 "%s:%d -- ", file, line);
-      fprintf (procfs_file ? procfs_file : stdout, msg);
+      fprintf (procfs_file ? procfs_file : stdout, "%s", msg);
       if (procfs_file)
        fflush (procfs_file);
     }
This page took 0.02482 seconds and 4 git commands to generate.