locked
Sporadic crash in application in Windows 10 RRS feed

  • Question

  • Just a quick note of an issue that i found.  I have a command line application, built in C++ in visual studio 2008. Very stable in all Windows platforms from XP to Windows 8.   A user migrated to Windows 10 and the app periodically crashed.  I put together a Windows 10 test system, and also got periodic crashes.  Managed to get it into debug and the crash location made no sense. The crash was occurring in the file open function, but the program was far past that function - well into the processing portion.  In days of old, this usually meant a stack issue.  I was trying alot of things, then I increased the Stack Reserve Size from 0 to 200000 and the Stack Commit Size from 0  to 100000 in the Link-> system property page.  Viola -  the issue went away.  I'm still researching exactly what the frick is going on, but thought I'd put a data point out there, in case anyone else is seeing sporadic Windows 10 issues.     

    • Moved by CoolDadTx Tuesday, November 10, 2015 4:30 PM C++ related
    Tuesday, November 10, 2015 4:17 PM

Answers

  • It sounds very much like you have produced undefined behavior.  It frequently manifests itself long after the immediate cause.

    Common causes are using the indeterminate value of an automatic variable, index out of range, or accessing memory after free/delete.

    • Proposed as answer by chchlll Friday, November 13, 2015 7:43 AM
    • Marked as answer by Shu 2017 Tuesday, November 24, 2015 5:16 AM
    Tuesday, November 10, 2015 7:01 PM

All replies

  • It sounds very much like you have produced undefined behavior.  It frequently manifests itself long after the immediate cause.

    Common causes are using the indeterminate value of an automatic variable, index out of range, or accessing memory after free/delete.

    • Proposed as answer by chchlll Friday, November 13, 2015 7:43 AM
    • Marked as answer by Shu 2017 Tuesday, November 24, 2015 5:16 AM
    Tuesday, November 10, 2015 7:01 PM
  • I agree with Barry. This smells of a memory corruption issue. These can be very difficult to troubleshoot. In my experience, a very careful code review (hopefully with eyes other than your own) can often spot coding issues such as buffer overruns, allocation/deallocation mismatches, dangling pointers, etc.
    Tuesday, November 10, 2015 10:08 PM