Go to Post Sometimes it's not about being fair. Some people are just very good at what they do. - Koko Ed [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #6   Spotlight this post!  
Unread 20-03-2005, 13:45
Mark McLeod's Avatar
Mark McLeod Mark McLeod is offline
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,856
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Printf Oddity : Programming Challange

These are the classic symptoms of a memory overwrite.

Usually the problem isn't caused by the statements you are fiddling with. Changing the "vital" statements simply causes things to be relocated/reorganized in the link map. I bet the overwrite is still happening, but it's probably overwriting unimportant locations now like unassigned space or variables that get initialized later anyway.

One way to track it down is to cause the error, look in the link map for the data memory location where you know the results are bad, then backtrack to see what is located before that corrupted memory location.

The cause, for instance, might be writing more values to an array than it is sized for. The extra values will clobber the next n memory bytes, one of which happens to be "vital", a static variable for example.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Programming - Getting Started Mark McLeod Programming 80 16-04-2008 23:37
Organizing a programming team. scitobor 617 Programming 7 28-01-2005 19:18
Default Code and printf WilsonDJ00 Programming 2 22-01-2005 16:39
Robot Programming Education phrontist Programming 11 03-05-2004 07:32
Anyone with a replacement Printf? Larry Barello Programming 5 19-03-2004 02:20


All times are GMT -5. The time now is 00:19.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi