User forums > Using Code::Blocks

Probably a bug!

(1/2) > >>

198710:
My c++ code about stl_list is complied with warning :" '__p' might be used uninitialized in this function " under the circumstance where "codeblocks-8.02mingw-setup.exe" is installed.
However,the warnings no longer exist if I install "codeblocks-8.02-setup.exe" and MinGW separately,thus I guess it's C::B's integration problem because I even tried to replace the "MinGW" folder and "mingwm10.dll" under codeblocks program directory.
Here's my code(in the attachment)

[attachment deleted by admin]

zabzonk:
Your code is syntactically correct (though you really should be using const references as function parameters in several places). Possibly this  is a problem with the old verdion of GCC  that comes with the CB release version. If using a later version of GCC fixes the problem, as seems to be the case, I don't think you have anything to worry about.

198710:
Well,then did you notice I said "I even tried to replace the "MinGW" folder and "mingwm10.dll" under codeblocks program directory"?
I replaced the default MinGW folder and "mingwm10.dll" inside "codeblocks-8.02mingw-setup.exe" with the "correct-compile-result" MinGW folder and "mingwm10.dll",still warnings...

zabzonk:
You said:

However,the warnings no longer exist if I install "codeblocks-8.02-setup.exe" and MinGW separately,

so I'm a bit confused as to what your problem is - are you still getting warnings or not? And which version of MinGW are you installing separately?

 

198710:
On my local machine,I installed "codeblocks-8.02mingw-setup.exe";
On my Virtual PC 2007(virtual WinXP guest),I installed "codeblocks-8.02-setup.exe" and MinGW separately,and the MinGW version is "MinGW-5.1.6.exe" from http://sourceforge.net/projects/mingw/files/;
Then I deleted the folder "C:\Program Files\CodeBlocks\MinGW" on my local machine,copied "C:\MinGW"(virtual machine) to "C:\Program Files\CodeBlocks\MinGW"(local machine),and replaced "C:\Program Files\CodeBlocks\mingwm10.dll"(local machine) with "C:\MinGW\bin\mingwm10.dll"(virtual machine) as well.
Warnings never occur on the virtual machine and never disappear on the local one.

Navigation

[0] Message Index

[#] Next page

Go to full version