diff options
author | Steve Chamberlain <steve@cygnus> | 1991-05-10 19:33:37 +0000 |
---|---|---|
committer | Steve Chamberlain <steve@cygnus> | 1991-05-10 19:33:37 +0000 |
commit | e5b919b168780f68a70efc886a3d2fab15113f28 (patch) | |
tree | acc8d8d889ed5a0e14fbdc01f75f82aab3ae8538 /bfd/coffswap.c | |
parent | af773d1b0f242711062d964dd222d020e1f1af5b (diff) | |
download | gdb-e5b919b168780f68a70efc886a3d2fab15113f28.zip gdb-e5b919b168780f68a70efc886a3d2fab15113f28.tar.gz gdb-e5b919b168780f68a70efc886a3d2fab15113f28.tar.bz2 |
Fixed all the places where there were problems with the size and
alignments of structures on disk and structures in memory. #ifed out
all the code in coffswap.c, since it should be done using the target
swap routines now.
Diffstat (limited to 'bfd/coffswap.c')
-rwxr-xr-x | bfd/coffswap.c | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/bfd/coffswap.c b/bfd/coffswap.c index eef2c96..78aea53 100755 --- a/bfd/coffswap.c +++ b/bfd/coffswap.c @@ -26,15 +26,15 @@ You should have received a copy of the GNU General Public License along with #include "libcoff.h" /* to allow easier abstraction-breaking */ #define sp(x) bfd_h_put_x(abfd, x, &x) +#if 0 +/* All the generic swapping routines: -/* All the swapping routines: - - FIXME, these routines assume that the sizes, alignments, and offsets of - these fields are the same in the host and target. This is an invalid - assumption, which in particular breaks on the 386 and SPARC. Fix this - the same way that a.out.h and sunos.c were fixed: define char arrays - that represent the headers in the target systems' file, and have these - functions translate in from that format, and out to that format. */ +FIXME + These routines cater for the sizes and alignments and offsets of + all the contained fields. Because of this, the fields can change + size, so these should be phased out to use the ones specific to the + file format. + */ void DEFUN(bfd_coff_swap_name,(abfd, ptr), @@ -53,7 +53,7 @@ DEFUN(bfd_coff_swap_name,(abfd, ptr), void DEFUN(bfd_coff_swap_sym,(abfd, se), bfd *abfd AND - SYMENT *se) + struct internal_syment *se) { bfd_coff_swap_name(abfd, (long*)(se->n_name)); bfd_h_put_x(abfd, se->n_value, &se->n_value); @@ -66,7 +66,7 @@ DEFUN(bfd_coff_swap_sym,(abfd, se), void DEFUN(bfd_coff_swap_aux,(abfd, au, type, class), bfd *abfd AND - AUXENT *au AND + struct internal_auxent *au AND int type AND int class) { @@ -112,10 +112,12 @@ DEFUN(bfd_coff_swap_aux,(abfd, au, type, class), void DEFUN(bfd_coff_swap_lineno,(abfd, lineno), bfd *abfd AND - LINENO *lineno) + struct internal_lineno *lineno) { sp(lineno->l_addr.l_symndx); sp(lineno->l_lnno); } + +#endif |