www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/08/14/04:21:32

From: fesenko AT pacific DOT net DOT sg (Victor)
Newsgroups: comp.os.msdos.djgpp
Subject: [Q] wrapping functions with linker
Date: Thu, 14 Aug 1997 18:54:22 GMT
Organization: Subscriber, Pacific Internet, Singapore
Lines: 23
Message-ID: <5stvfi$ffm$1@newton.pacific.net.sg>
NNTP-Posting-Host: dyn84ppp208.pacific.net.sg
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

When I'm trying to wrap malloc() related routines to use my functions
instead, I get this GPF. This is how I compile and run it :

gcc -I. -Isrc -Wall -O -g -o obj/print.o -c print.c
gcc
-Wl,--wrap,malloc,--wrap,calloc,--wrap,cfree,--wrap,realloc,--wrap,free,
--wrap,xmalloc,--wrap,realloc,--wrap,xfree -o print.exe obj/print.o
-lm -lscan -lalleg -lpc
 
 
General Protection Fault at eip=1af61; flags=3056
eax=00000025 ebx=0000000e ecx=fffe6ad1 edx=0001cc85 esi=0001cc2b
edi=00000123	ebp=00000123 esp=00003006 cs=a7 ds=af es=af fs=8f
gs=bf ss=33 error=0000
 

My programs run OK if I substitute those functions only in my source
and some of the libraries, but when I'm trying to substitute those
functions in all the libraries, than I'm getting this error.
Any ideas appreciated.

Victor Fesenko.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019