/* Read hp debug symbols and convert to internal format, for GDB.
- Copyright 1993, 1996, 1998, 1999 Free Software Foundation, Inc.
+ Copyright 1993, 1996, 1998, 1999, 2000 Free Software Foundation, Inc.
This file is part of GDB.
#include <stdlib.h>
#include <string.h>
-/* check for the existance of a file, given its full pathname */
+/* check for the existence of a file, given its full pathname */
int
file_exists (char *filename)
{
/* Call PXDB to process our file.
Approach copied from DDE's "dbgk_run_pxdb". Note: we
- don't check for BSD location of pxdb, nor for existance
+ don't check for BSD location of pxdb, nor for existence
of pxdb itself, etc.
NOTE: uses system function and string functions directly.
if (file_exists (PXDB_SVR4))
{
- p = malloc (strlen (PXDB_SVR4) + strlen (file_name) + 2);
+ p = xmalloc (strlen (PXDB_SVR4) + strlen (file_name) + 2);
strcpy (p, PXDB_SVR4);
strcat (p, " ");
strcat (p, file_name);
{
pst_syms_count = 0;
pst_syms_size = 0;
- free (pst_syms_array);
+ xfree (pst_syms_array);
pst_syms_array = 0;
}
static_syms);
/* Set up to only enter each class referenced in this module once. */
- class_entered = malloc (B_BYTES (pxdb_header_p->cd_entries));
+ class_entered = xmalloc (B_BYTES (pxdb_header_p->cd_entries));
B_CLRALL (class_entered, pxdb_header_p->cd_entries);
/* Scan the procedure descriptors for procedures in the current
/* Prepare for the next psymtab. */
global_syms = objfile->global_psymbols.next;
static_syms = objfile->static_psymbols.next;
- free (class_entered);
+ xfree (class_entered);
curr_fd++;
} /* Psymtab for file */
static_syms);
/* Set up to only enter each class referenced in this module once. */
- class_entered = malloc (B_BYTES (pxdb_header_p->cd_entries));
+ class_entered = xmalloc (B_BYTES (pxdb_header_p->cd_entries));
B_CLRALL (class_entered, pxdb_header_p->cd_entries);
/* Scan the procedure descriptors for procedures in the current
/* Prepare for the next psymtab. */
global_syms = objfile->global_psymbols.next;
static_syms = objfile->static_psymbols.next;
- free (class_entered);
+ xfree (class_entered);
curr_md++;
curr_fd++;
/* Get the low address associated with some symbol (typically the start
of a particular source file or module). Since that information is not
- stored as part of the DNTT_TYPE_MODULE or DNTT_TYPE_SRCFILE symbol we must infer it from
- the existance of DNTT_TYPE_FUNCTION symbols. */
+ stored as part of the DNTT_TYPE_MODULE or DNTT_TYPE_SRCFILE symbol we
+ must infer it from the existence of DNTT_TYPE_FUNCTION symbols. */
static unsigned long
hpread_get_textlow (int global, int index, struct objfile *objfile,