Using Electric Fence

To use Electric Fence, you just need to link in the efence library during the last stage of linking (or compilation, if you do not have a separate link step):

gcc -g -Wall -Wstrict-prototypes -lefence test.c

When you run your program, it should print a message to the screen indicating that Electric Fence is in use. If your program segfaults, it will not show you where it occurred, but you can then debug the program with gdb to determine this information (section [*]).