delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2007/03/23/06:31:48

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
From: tim DOT nicholson AT skyforcekent DOT com
Newsgroups: comp.os.msdos.djgpp
Subject: protecting program memory
Date: 23 Mar 2007 04:16:50 -0700
Organization: http://groups.google.com
Lines: 16
Message-ID: <1174648609.965097.60210@b75g2000hsg.googlegroups.com>
NNTP-Posting-Host: 217.155.149.201
Mime-Version: 1.0
X-Trace: posting.google.com 1174648611 16541 127.0.0.1 (23 Mar 2007 11:16:51 GMT)
X-Complaints-To: groups-abuse AT google DOT com
NNTP-Posting-Date: Fri, 23 Mar 2007 11:16:51 +0000 (UTC)
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.2) Gecko/20060601 Firefox/2.0.0.2 (Ubuntu-edgy),gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.1 localhost:8080 (squid/2.5.STABLE9)
Complaints-To: groups-abuse AT google DOT com
Injection-Info: b75g2000hsg.googlegroups.com; posting-host=217.155.149.201;
posting-account=lGMSoA0AAAAj3K6TdfxB2w_vj0YEAdck
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Is there an easy way to protect the memory used to store the program
op codes from a rogue memory write from within the application? I have
a large (100,000+ line) DJGPP application which sometimes crashes with
SIGILL - It would seem the program is cannibalizing itself! In order
to find how this is happening, I would like to protect the entire
block of memory that contains the application code so that an
exception occurs at the point the corruption occurs rather than the
point that the corrupted code is executed.

I guest I need to make the memory block read only, but I am not sure
how to do that.

Thanks

Tim

- Raw text -


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