CS 102 Lab #9

This lab will give you practice with the debugger on our system, gdb. The file debug.C contains code that manipulates pointers, but there are several errors in the code. You must fix the code, and will use gdb to find out where the program is crashing and learn more about why.

The program uses a Node structure like the one in the last lab, and links together a short list of them. (It does not use any sort of list class -- it manipulates the pointers directly.) After building the list the code prints out its contents, then tests a function called Member that looks to see if a particular value is in the list.

Perform the following steps:

Unfortunately, there's a second error in your program, as you can see if you try to run it. Use the debugger again to find out where the program died and try to understand why.