If its looping, run it through a debugger. If you haven't got one, or think its not practicle to use one, try putting lots of printf("checkpoint 1"); type statements in the code to help you pin-point the problem area.
If its looping, run it through a debugger. If you haven't got one, or think its not practicle to use one, try putting lots of printf("checkpoint 1"); type statements in the code to help you pin-point the problem area.
When all else fails, read the instructions.
If you're posting code, use code tags: [code] /* insert code here */ [/code]