Removed superflous code.
[deliverable/binutils-gdb.git] / gdb / core-sol2.c
index 13d987692b03d7443ad13d864a88b45cbd33e6a1..0c5eac1aaf671e559ddfdd866b38e5d0c6cb9406 100644 (file)
@@ -15,14 +15,14 @@ GNU General Public License for more details.
 
 You should have received a copy of the GNU General Public License
 along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 
 /* Solaris comes with two flavours of core files, cores generated by
    an ELF executable and cores generated by programs that were
    run under BCP (the part of Solaris which allows it to run SunOS4
    a.out files).
-   This file combines the core register fetching from core-svr4.c
+   This file combines the core register fetching from core-regset.c
    and sparc-nat.c to be able to read both flavours.  */
 
 #include "defs.h"
@@ -30,6 +30,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
 #undef fpregset_t
 
 #include <time.h>
+#include <sys/types.h>
 #include <sys/regset.h>
 #include <sys/procfs.h>
 #include <fcntl.h>
@@ -41,12 +42,14 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
 #include "command.h"
 #include "gdbcore.h"
 
-void
+static void fetch_core_registers PARAMS ((char *, unsigned, int, CORE_ADDR));
+
+static void
 fetch_core_registers (core_reg_sect, core_reg_size, which, reg_addr)
      char *core_reg_sect;
      unsigned core_reg_size;
      int which;
-     unsigned int reg_addr;    /* Unused in this version */
+     CORE_ADDR reg_addr;       /* Unused in this version */
 {
   prgregset_t prgregset;
   prfpregset_t prfpregset;
@@ -115,3 +118,19 @@ fetch_core_registers (core_reg_sect, core_reg_size, which, reg_addr)
        }
     }
 }
+
+\f
+/* Register that we are able to handle solaris core file formats. */
+
+static struct core_fns solaris_core_fns =
+{
+  bfd_target_elf_flavour,
+  fetch_core_registers,
+  NULL
+};
+
+void
+_initialize_core_solaris ()
+{
+  add_core_fns (&solaris_core_fns);
+}
This page took 0.025845 seconds and 4 git commands to generate.