Some setting in XP allows computer to reboot after error occurs in PC. Follow steps given below to fix the problem:
• Go to Start then open Control Panel
• Click Performance and Maintenance, go to System then Advanced Tab
• Click Settings in Startup and Recovery section
• After that Uncheck Automatically reboot the computer failure section. It will fix your problem.