Fixed conditional debugging text loading on second+ game load. Variable cleanup was mainly using free(), but code was testing prior usage with if(variable) coding, evaluating to true from the random data, and feeding the freed variables to functions.
This commit is contained in:
parent
cd6fe07f8e
commit
1a98ae6284
|
@ -223,6 +223,19 @@ int loadDebuggerPreferences(FILE* f)
|
|||
|
||||
myNumWPs = 0;
|
||||
|
||||
// Ugetab:
|
||||
// This took far too long to figure out...
|
||||
// Nullifying the data is better than using free(), because
|
||||
// a simple if(watchpoint[i].cond) can still evaluate to true.
|
||||
// This causes several tests to fail, one of which kills
|
||||
// conditional text loading when reusing a used condText.
|
||||
for (i=0;i<65;i++)
|
||||
{
|
||||
watchpoint[i].cond = NULL;
|
||||
watchpoint[i].condText = NULL;
|
||||
watchpoint[i].desc = NULL;
|
||||
}
|
||||
|
||||
// Read the breakpoints
|
||||
for (i=0;i<65;i++)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue