mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-24 04:00:07 +08:00
Sun Feb 27 15:22:36 1994 Stan Shebs (shebs@andros.cygnus.com)
* targets.c (BFD_SEND, BFD_SEND_FMT): Add debugging versions that check all the pointer dereferences. Enabled via DEBUG_BFD_SEND. * bfd-in2.h: Rebuilt.
This commit is contained in:
@ -1,5 +1,9 @@
|
|||||||
Sun Feb 27 15:22:36 1994 Stan Shebs (shebs@andros.cygnus.com)
|
Sun Feb 27 15:22:36 1994 Stan Shebs (shebs@andros.cygnus.com)
|
||||||
|
|
||||||
|
* targets.c (BFD_SEND, BFD_SEND_FMT): Add debugging versions that
|
||||||
|
check all the pointer dereferences. Enabled via DEBUG_BFD_SEND.
|
||||||
|
* bfd-in2.h: Rebuilt.
|
||||||
|
|
||||||
* srec.c (hex_value): Always set to a size of 256 bytes.
|
* srec.c (hex_value): Always set to a size of 256 bytes.
|
||||||
(srec_init): Cosmetic changes.
|
(srec_init): Cosmetic changes.
|
||||||
|
|
||||||
|
@ -756,6 +756,12 @@ typedef struct sec
|
|||||||
discarded. */
|
discarded. */
|
||||||
#define SEC_DEBUGGING 0x10000
|
#define SEC_DEBUGGING 0x10000
|
||||||
|
|
||||||
|
/* The contents of this section are held in memory pointed to
|
||||||
|
by the contents field. This is checked by
|
||||||
|
bfd_get_section_contents, and the data is retrieved from
|
||||||
|
memory if appropriate. */
|
||||||
|
#define SEC_IN_MEMORY 0x20000
|
||||||
|
|
||||||
/* End of section flags. */
|
/* End of section flags. */
|
||||||
|
|
||||||
/* The virtual memory address of the section - where it will be
|
/* The virtual memory address of the section - where it will be
|
||||||
@ -835,7 +841,9 @@ typedef struct sec
|
|||||||
|
|
||||||
PTR userdata;
|
PTR userdata;
|
||||||
|
|
||||||
struct lang_output_section *otheruserdata;
|
/* If the SEC_IN_MEMORY flag is set, this points to the actual
|
||||||
|
contents. */
|
||||||
|
unsigned char *contents;
|
||||||
|
|
||||||
/* Attached line number information */
|
/* Attached line number information */
|
||||||
|
|
||||||
@ -1924,8 +1932,24 @@ core_file_matches_executable_p
|
|||||||
|
|
||||||
#define BFD_SEND(bfd, message, arglist) \
|
#define BFD_SEND(bfd, message, arglist) \
|
||||||
((*((bfd)->xvec->message)) arglist)
|
((*((bfd)->xvec->message)) arglist)
|
||||||
|
|
||||||
|
#ifdef DEBUG_BFD_SEND
|
||||||
|
#undef BFD_SEND
|
||||||
|
#define BFD_SEND(bfd, message, arglist) \
|
||||||
|
(((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
|
||||||
|
((*((bfd)->xvec->message)) arglist) : \
|
||||||
|
(bfd_assert (__FILE__,__LINE__), NULL))
|
||||||
|
#endif
|
||||||
#define BFD_SEND_FMT(bfd, message, arglist) \
|
#define BFD_SEND_FMT(bfd, message, arglist) \
|
||||||
(((bfd)->xvec->message[(int)((bfd)->format)]) arglist)
|
(((bfd)->xvec->message[(int)((bfd)->format)]) arglist)
|
||||||
|
|
||||||
|
#ifdef DEBUG_BFD_SEND
|
||||||
|
#undef BFD_SEND_FMT
|
||||||
|
#define BFD_SEND_FMT(bfd, message, arglist) \
|
||||||
|
(((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
|
||||||
|
(((bfd)->xvec->message[(int)((bfd)->format)]) arglist) : \
|
||||||
|
(bfd_assert (__FILE__,__LINE__), NULL))
|
||||||
|
#endif
|
||||||
enum bfd_flavour {
|
enum bfd_flavour {
|
||||||
bfd_target_unknown_flavour,
|
bfd_target_unknown_flavour,
|
||||||
bfd_target_aout_flavour,
|
bfd_target_aout_flavour,
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Generic target-file-type support for the BFD library.
|
/* Generic target-file-type support for the BFD library.
|
||||||
Copyright 1990, 91, 92, 93, 94 Free Software Foundation, Inc.
|
Copyright 1990, 91, 92, 93, 1994 Free Software Foundation, Inc.
|
||||||
Written by Cygnus Support.
|
Written by Cygnus Support.
|
||||||
|
|
||||||
This file is part of BFD, the Binary File Descriptor library.
|
This file is part of BFD, the Binary File Descriptor library.
|
||||||
@ -102,11 +102,27 @@ DESCRIPTION
|
|||||||
|
|
||||||
.#define BFD_SEND(bfd, message, arglist) \
|
.#define BFD_SEND(bfd, message, arglist) \
|
||||||
. ((*((bfd)->xvec->message)) arglist)
|
. ((*((bfd)->xvec->message)) arglist)
|
||||||
|
.
|
||||||
|
.#ifdef DEBUG_BFD_SEND
|
||||||
|
.#undef BFD_SEND
|
||||||
|
.#define BFD_SEND(bfd, message, arglist) \
|
||||||
|
. (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
|
||||||
|
. ((*((bfd)->xvec->message)) arglist) : \
|
||||||
|
. (bfd_assert (__FILE__,__LINE__), NULL))
|
||||||
|
.#endif
|
||||||
|
|
||||||
For operations which index on the BFD format:
|
For operations which index on the BFD format:
|
||||||
|
|
||||||
.#define BFD_SEND_FMT(bfd, message, arglist) \
|
.#define BFD_SEND_FMT(bfd, message, arglist) \
|
||||||
. (((bfd)->xvec->message[(int)((bfd)->format)]) arglist)
|
. (((bfd)->xvec->message[(int)((bfd)->format)]) arglist)
|
||||||
|
.
|
||||||
|
.#ifdef DEBUG_BFD_SEND
|
||||||
|
.#undef BFD_SEND_FMT
|
||||||
|
.#define BFD_SEND_FMT(bfd, message, arglist) \
|
||||||
|
. (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
|
||||||
|
. (((bfd)->xvec->message[(int)((bfd)->format)]) arglist) : \
|
||||||
|
. (bfd_assert (__FILE__,__LINE__), NULL))
|
||||||
|
.#endif
|
||||||
|
|
||||||
This is the structure which defines the type of BFD this is. The
|
This is the structure which defines the type of BFD this is. The
|
||||||
<<xvec>> member of the struct <<bfd>> itself points here. Each
|
<<xvec>> member of the struct <<bfd>> itself points here. Each
|
||||||
@ -353,6 +369,7 @@ extern bfd_target bfd_elf32_little_generic_vec;
|
|||||||
extern bfd_target bfd_elf32_littlemips_vec;
|
extern bfd_target bfd_elf32_littlemips_vec;
|
||||||
extern bfd_target bfd_elf32_m68k_vec;
|
extern bfd_target bfd_elf32_m68k_vec;
|
||||||
extern bfd_target bfd_elf32_m88k_vec;
|
extern bfd_target bfd_elf32_m88k_vec;
|
||||||
|
extern bfd_target bfd_elf32_powerpc_vec;
|
||||||
extern bfd_target bfd_elf32_sparc_vec;
|
extern bfd_target bfd_elf32_sparc_vec;
|
||||||
extern bfd_target bfd_elf64_big_generic_vec;
|
extern bfd_target bfd_elf64_big_generic_vec;
|
||||||
extern bfd_target bfd_elf64_little_generic_vec;
|
extern bfd_target bfd_elf64_little_generic_vec;
|
||||||
@ -389,6 +406,9 @@ extern bfd_target newsos3_vec;
|
|||||||
extern bfd_target nlm32_i386_vec;
|
extern bfd_target nlm32_i386_vec;
|
||||||
extern bfd_target nlm32_sparc_vec;
|
extern bfd_target nlm32_sparc_vec;
|
||||||
extern bfd_target nlm32_alpha_vec;
|
extern bfd_target nlm32_alpha_vec;
|
||||||
|
/*start-sanitize-powerpc-netware*/
|
||||||
|
extern bfd_target nlm32_powerpc_vec;
|
||||||
|
/*end-sanitize-powerpc-netware*/
|
||||||
extern bfd_target oasys_vec;
|
extern bfd_target oasys_vec;
|
||||||
extern bfd_target rs6000coff_vec;
|
extern bfd_target rs6000coff_vec;
|
||||||
extern bfd_target shcoff_vec;
|
extern bfd_target shcoff_vec;
|
||||||
|
Reference in New Issue
Block a user