Memory Corruption with AAs

Walter Bright newshound1 at digitalmars.com
Sat Apr 3 00:11:15 PDT 2010


Steve Teale wrote:
> On Sat, 03 Apr 2010 06:24:20 +0000, Steve Teale wrote:
> 
>> On Fri, 02 Apr 2010 23:01:48 -0700, Walter Bright wrote:
>>  
>>>>> Since it is single-threaded, it should crash in the same place in
>>>>> the
>>> same way every time. This means you can put an assert on the crashing
>>> data (even without gdb it can be found by inserting printf's), and
>>> slowly work it backward to where the data goes wrong.
>> According to an article I was reading that constancy does not apply with
>> current Linux kernels. They deliberately randomize things to make life
>> difficult for hackers.
>>
>> I'll try to find it again - it's about debugging GCC itself.
>>
>> Steve
> 
> Got it - http://gcc.gnu.org/wiki/DebuggingGCC
> 
> Right at the end.

It links to this page which shows how to turn it off:

http://gcc.gnu.org/wiki/Randomization



More information about the Digitalmars-d mailing list