diff options
author | Stu Grossman <grossman@cygnus> | 1991-10-25 23:10:12 +0000 |
---|---|---|
committer | Stu Grossman <grossman@cygnus> | 1991-10-25 23:10:12 +0000 |
commit | 159a075e55ceb12b6ded208d243beb7ad36e577c (patch) | |
tree | 74dc6a787b8fe300eaa47697e06779c5f917184e | |
parent | 40458cc92c67b6294b4705b50c486538b5dc728e (diff) | |
download | gdb-159a075e55ceb12b6ded208d243beb7ad36e577c.zip gdb-159a075e55ceb12b6ded208d243beb7ad36e577c.tar.gz gdb-159a075e55ceb12b6ded208d243beb7ad36e577c.tar.bz2 |
* coffread.c, coredep.c, i386-xdep.c: install patches for
SysV/386 3.2 from Mauro DePalma.
-rw-r--r-- | gdb/coffread.c | 23 | ||||
-rw-r--r-- | gdb/coredep.c | 2 | ||||
-rw-r--r-- | gdb/i386-xdep.c | 4 |
3 files changed, 18 insertions, 11 deletions
diff --git a/gdb/coffread.c b/gdb/coffread.c index 37c5af3..d579413 100644 --- a/gdb/coffread.c +++ b/gdb/coffread.c @@ -106,7 +106,7 @@ static int symnum; /* Vector of types defined so far, indexed by their coff symnum. */ -static struct typevector *type_vector; +static struct type **type_vector; /* Number of elements allocated for type_vector currently. */ @@ -267,13 +267,12 @@ coff_lookup_type (index) if (type_vector_length < index) { type_vector_length = index * 2; } - type_vector = (struct typevector *) - xrealloc (type_vector, sizeof (struct typevector) - + type_vector_length * sizeof (struct type *)); - bzero (&type_vector->type[ old_vector_length ], + type_vector = (struct type **) + xrealloc (type_vector, type_vector_length * sizeof (struct type *)); + bzero (&type_vector[old_vector_length], (type_vector_length - old_vector_length) * sizeof(struct type *)); } - return &type_vector->type[index]; + return &type_vector[index]; } /* Make sure there is a type allocated for type number index @@ -295,6 +294,7 @@ coff_alloc_type (index) type = (struct type *) obstack_alloc (symbol_obstack, sizeof (struct type)); bzero (type, sizeof (struct type)); + TYPE_VPTR_FIELDNO (type) = -1; *type_addr = type; } return type; @@ -892,10 +892,9 @@ read_coff_symtab (desc, nsyms) if (type_vector) /* Get rid of previous one */ free (type_vector); type_vector_length = 160; - type_vector = (struct typevector *) - xmalloc (sizeof (struct typevector) - + type_vector_length * sizeof (struct type *)); - bzero (type_vector->type, type_vector_length * sizeof (struct type *)); + type_vector = (struct type **) + xmalloc (type_vector_length * sizeof (struct type *)); + bzero (type_vector, type_vector_length * sizeof (struct type *)); start_symtab (); @@ -2126,7 +2125,11 @@ static struct sym_fns coff_sym_fns = #if defined (TDESC) "m88kbcs", 8, #else /* not TDESC */ +# ifdef i386 + "i386coff", 8, +# else "coff", 4, +# endif /* not i386 */ #endif /* not TDESC */ coff_new_init, coff_symfile_init, coff_symfile_read, }; diff --git a/gdb/coredep.c b/gdb/coredep.c index 6eec85a..87be349 100644 --- a/gdb/coredep.c +++ b/gdb/coredep.c @@ -28,11 +28,11 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ /* These are needed on various systems to expand REGISTER_U_ADDR. */ #include <sys/types.h> #include <sys/param.h> +#ifndef USG #include <sys/dir.h> #include <sys/file.h> #include <sys/stat.h> #include <sys/user.h> -#ifndef USG #include <sys/ptrace.h> #endif diff --git a/gdb/i386-xdep.c b/gdb/i386-xdep.c index 243e057..13ac213 100644 --- a/gdb/i386-xdep.c +++ b/gdb/i386-xdep.c @@ -81,6 +81,9 @@ i386_register_u_addr (blockend, regnum) } +#if 0 +/* mauro@olympus 1991.10.20 -- compiling the following code causes + undefined symbols at link time, specifically: corechan, have_inferior_p */ struct env387 { unsigned short control; @@ -239,3 +242,4 @@ i386_float_info () fpstatep = (struct fpstate *)(buf + skip); print_387_status (fpstatep->status, (struct env387 *)fpstatep->state); } +#endif /* mauro@olympus 1991.10.20 */ |