Try running in the debug mode and see where the program is crashing or giving any ASSERT.