I encountered a problem in my C program. When the code runs for a short time, there is no error at all. But when it runs for 1 or 2 hours, it terminates with the message: "...instruction at xxxxx referenced by xxxxx could be written....
Anybody can give me some idea of what kind of problem it is and how should I deal with it? Thanks a lot
Regards
> I encountered a problem in my C program. When the code runs for a short time, there is no error at all. But when it runs for 1 or 2 hours, it terminates with the message: "...instruction at xxxxx referenced by xxxxx could be written.... "
>
> Anybody can give me some idea of what kind of problem it is and how should I deal with it? Thanks a lot!
>
> Regards
Hi Haitao,
Without more information it's pretty hard to see what's going on. One
possibility is you have a memory leak or buffer under/overflow which
isn't apparent at first, but eventually starts corrupting memory used by
your program, resulting in the errors you mentioned. You might want to
try some kind of memory profiling when testing your program to see
whether it is indeed leaking or under/overflowing.
Cheers
Pete