views:

31

answers:

2

When you have a Debug version of a C++ program running on an OS that has no VS or CRT installed, will you still get Debug Assertion error boxes?

The ones that say "Debug Assert Failed!".

Or will you only get them when the machine has certain components, such as CRT or Visual Studio installed?

+2  A: 

It depends how you've built your application. If you're dynamically linking to the debug CRT then it's very unlikely the user will have the debug CRTs on their system unless they're developers (and in fact you can't distribute it due to the licensing of VS). So in this case it won't even run. If you statically link to the CRT then the user will see the asserts if you've shipped them a debug build.

the_mandrill
+1  A: 

If you can get it to run, yes. Compiling with /MDd (the default) requires distributing the debug version of the dynamic CRT. It is not a redistributable component, shipping it anyway is a license violation. You could get around it by compiling with /MTd.

Of course, your user will have no idea what "Debug assertion failed" means and won't understand why Ignore doesn't work. Best avoided.

Hans Passant