Thread: Debugging and unhandled exception

  1. #1
    Registered User
    Join Date
    Jan 2006
    Location
    Latvia
    Posts
    102

    Debugging and unhandled exception

    Hi. Currently when I launch my program it causes an unhandled exception and crashes, but everything works fine while debugging. I tried to tamper with the optimizations, but they are already off. What could be the reason for this?

    Is there any way to somehow debug my code? Which options should I change to be able to do so?

    Thanks, I can provide more information if needed.


    Using MSVC++2008

  2. #2
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,195
    bad pointers.

    is this C/C++ or C#. MFC, ATL, STL, Win32 API?

    Could you post the code that is crashing?

    Have you tried running the debugger to find the line that crashes?

  3. #3
    train spotter
    Join Date
    Aug 2001
    Location
    near a computer
    Posts
    3,868
    Quote Originally Posted by Overlord View Post
    Is there any way to somehow debug my code?
    Log progress to a file, narrowing the logged secions down until you find the cause.

    Exception handlers (try/catch)

    Message boxes.
    "Man alone suffers so excruciatingly in the world that he was compelled to invent laughter."
    Friedrich Nietzsche

    "I spent a lot of my money on booze, birds and fast cars......the rest I squandered."
    George Best

    "If you are going through hell....keep going."
    Winston Churchill

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Unhandled exceptions (throw with no try)
    By Mario F. in forum C++ Programming
    Replies: 3
    Last Post: 07-01-2006, 06:31 AM
  2. Unhandled exception: User breakpoint
    By glUser3f in forum C++ Programming
    Replies: 3
    Last Post: 10-02-2003, 04:20 PM