Skip to content
Advertisement

Tag: visual-studio-2015

Visual Studio 2015/Linux extension produces a “collect2 : error : ld returned 1 exit status” with Cygwin

I am currently trying the Linux Extension of Visual Studio 2015. I plan to have several target machines using various distribs. So far, my testing machine is a Windows 7 with an up-to-date Cygwin with all needed packages (openssh, g++, gdb…) installed. The test I’m conducting consists in a very simple C++ “Hello world” file, and the VS projects settings

Diifferetn result in Linux and Visual Studio

Does anybody know why compiling program in Visual Studio 2015 gives different result (those are correct I want to keep them) vs Linux Ubuntu (those are wrong).? Answer Reading beyond the end of an array invokes undefined behavior in C. Once your program invokes undefined behavior anything can happen or nothing at all. It is simply undefined. As aneesh correctly

Advertisement