geoteamy

Member
  • Content count

    1
  • Joined

  • Last visited

Community Reputation

101 Neutral

About geoteamy

  • Rank
    Newbie
  1. I am having a weird problem were i have a linked list system that creates objects and it works fine until i add any numeric variable to the main loop then it crash when it is deleting the objects [CODE] while (1)//this deletes the objects { if (root->next != NULL) { temp=root->next; delete root; root = temp; } else { break; } } [/CODE] This next part is the beginning of the main loop it works fine until i added the variable "test" after i added it, it crashes whenever i try to delete the whole list using the code above. [CODE] int main() { int test = 0; zombie master; zombie *root = &master; zombie *temp=NULL; [/CODE]