I got a very simple problem with the Visual Studio 2010 Professional C++ debugger when setting environment variables.
Described in
http://msdn.microsoft.com/en-en/library/kcw4dzyf.aspx
Paragraph "Environment (Local Windows Debugger)".
I created a standard Win32 console project. I am setting the environment in project properties → Debugger:
TEST=asdf
OTHER=qwer
And printing the environment variables in the _tmain(...):
cout << "Hello " << getenv("TEST") << endl;
I would expect an out like:
"Hello asdf"
But instead I always get:
"Hello asdf OTHER=qwer"
How to fix this?!
It seems to be a DEU version bug.
I just filed a bug report: https://connect.microsoft.com/VisualStudio/feedback/details/727324/msvs10-c-deu-debugger-environment-variables-missing-linefeed#details