From 47aca600bd9965d155d5b27bb42f9d2a61d4effa Mon Sep 17 00:00:00 2001 From: pk Date: Wed, 10 Nov 1993 21:40:50 +0000 Subject: [PATCH] Added function `md_set_breakpoint()'. --- gnu/usr.bin/ld/arch/i386/md.c | 10 +++++++++- gnu/usr.bin/ld/i386/md.c | 10 +++++++++- libexec/ld.aout_so/arch/i386/md.c | 10 +++++++++- 3 files changed, 27 insertions(+), 3 deletions(-) diff --git a/gnu/usr.bin/ld/arch/i386/md.c b/gnu/usr.bin/ld/arch/i386/md.c index bfe12e92c11d..3fb800719052 100644 --- a/gnu/usr.bin/ld/arch/i386/md.c +++ b/gnu/usr.bin/ld/arch/i386/md.c @@ -27,7 +27,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: md.c,v 1.2 1993/10/27 00:54:58 pk Exp $ + * $Id: md.c,v 1.3 1993/11/10 21:40:50 pk Exp $ */ #include @@ -233,6 +233,14 @@ struct relocation_info *rp, *r; r->r_copy = 1; } +void +md_set_breakpoint(where, savep) +long where; +long *savep; +{ + *savep = *(long *)where; + *(char *)where = TRAP; +} #ifdef NEED_SWAP diff --git a/gnu/usr.bin/ld/i386/md.c b/gnu/usr.bin/ld/i386/md.c index bfe12e92c11d..3fb800719052 100644 --- a/gnu/usr.bin/ld/i386/md.c +++ b/gnu/usr.bin/ld/i386/md.c @@ -27,7 +27,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: md.c,v 1.2 1993/10/27 00:54:58 pk Exp $ + * $Id: md.c,v 1.3 1993/11/10 21:40:50 pk Exp $ */ #include @@ -233,6 +233,14 @@ struct relocation_info *rp, *r; r->r_copy = 1; } +void +md_set_breakpoint(where, savep) +long where; +long *savep; +{ + *savep = *(long *)where; + *(char *)where = TRAP; +} #ifdef NEED_SWAP diff --git a/libexec/ld.aout_so/arch/i386/md.c b/libexec/ld.aout_so/arch/i386/md.c index bfe12e92c11d..3fb800719052 100644 --- a/libexec/ld.aout_so/arch/i386/md.c +++ b/libexec/ld.aout_so/arch/i386/md.c @@ -27,7 +27,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: md.c,v 1.2 1993/10/27 00:54:58 pk Exp $ + * $Id: md.c,v 1.3 1993/11/10 21:40:50 pk Exp $ */ #include @@ -233,6 +233,14 @@ struct relocation_info *rp, *r; r->r_copy = 1; } +void +md_set_breakpoint(where, savep) +long where; +long *savep; +{ + *savep = *(long *)where; + *(char *)where = TRAP; +} #ifdef NEED_SWAP