CppCheck report

Here you can discuss ReactOS related topics.

Moderator: Moderator Team

Post Reply
10_GOTO_10
Posts: 17
Joined: Sun Jun 12, 2011 11:55 pm
Location: France
Contact:

CppCheck report

Post by 10_GOTO_10 » Tue Nov 29, 2011 9:47 pm

Hi,

I have run CppCheck on ReactOS Code. I think there it found some reals bug. For example:
file="reactos\base\applications\notepad\main.c" line="518" id="uninitstring" severity="error" msg="Dangerous usage of 'buf' (strncpy doesn't always 0-terminate it)"

Code: Select all

                _tcsncpy(buf, cmdline, MAX_PATH - _tcslen(txt) - 1);
                _tcscat(buf, txt);
Yes, it is a bug
file="reactos\boot\freeldr\freeldr\arch\powerpc\loader.c" line="142" id="nullPointer" severity="error" msg="Possible null pointer dereference: Function - otherwise it is redundant to check if Function is null at line 140"

Code: Select all

                if (Function == NULL)
                {
                    DbgPrint("LdrPEGetExportByName(): failed to find %s\n", Function);
Yes, it will crash

Here the full report:
file="reactos\base\applications\calc\function.c" line="34" id="wrongmathcall" severity="error" msg="Passing value -1.0 to sqrt() leads to undefined result"
file="reactos\base\applications\calc\function.c" line="43" id="wrongmathcall" severity="error" msg="Passing value -1.0 to sqrt() leads to undefined result"
file="reactos\base\applications\network\ftp\ftp.c" line="220" id="fflushOnInputStream" severity="error" msg="fflush() called on input stream "stdin" may result in undefined behaviour"
file="reactos\base\applications\network\telnet\src\tnconfig.cpp" line="284" id="bufferAccessOutOfBounds" severity="error" msg="Buffer access out-of-bounds: exename"
file="reactos\base\applications\notepad\main.c" line="518" id="uninitstring" severity="error" msg="Dangerous usage of 'buf' (strncpy doesn't always 0-terminate it)"
file="reactos\base\services\svchost\svchost.c" line="51" id="uninitstring" severity="error" msg="Dangerous usage of 'ServiceKeyBuffer' (strncpy doesn't always 0-terminate it)"
file="reactos\base\shell\explorer\globals.h" line="240" id="useAutoPointerContainer" severity="error" msg="An element of container must be able to be copied but 'auto_ptr' does not fulfill this requirement. You should consider to use 'shared_ptr' or 'unique_ptr'. It is suitable for use in containers, because they no longer copy their values, they move them."
file="reactos\base\shell\explorer\shell\fatfs.cpp" line="475" id="memleakOnRealloc" severity="error" msg="Common realloc mistake: '_CacheDty' nulled but not freed upon failure"
file="reactos\base\shell\explorer\taskbar\startmenu.cpp" line="1170" id="unusedScopedObject" severity="error" msg="instance of "StartMenuCtrl" object destroyed immediately"
file="reactos\base\shell\explorer\taskbar\startmenu.cpp" line="1194" id="unusedScopedObject" severity="error" msg="instance of "StartMenuSeparator" object destroyed immediately"
file="reactos\base\shell\explorer\utility\xs-native.cpp" line="104" id="memleakOnRealloc" severity="error" msg="Common realloc mistake: '_buffer' nulled but not freed upon failure"
file="reactos\base\system\regsvr32\regsvr32.c" line="339" id="uninitvar" severity="error" msg="Uninitialized variable: lptMsgBuffer"
file="reactos\boot\freeldr\freeldr\arch\i386\drivemap.c" line="183" id="nullPointer" severity="error" msg="Possible null pointer dereference: RealModeIVT"
file="reactos\boot\freeldr\freeldr\arch\i386\drivemap.c" line="205" id="nullPointer" severity="error" msg="Possible null pointer dereference: RealModeIVT"
file="reactos\boot\freeldr\freeldr\arch\i386\drivemap.c" line="219" id="nullPointer" severity="error" msg="Possible null pointer dereference: RealModeIVT"
file="reactos\boot\freeldr\freeldr\arch\i386\xboxmem.c" line="59" id="nullPointer" severity="error" msg="Possible null pointer dereference: MembaseLow"
file="reactos\boot\freeldr\freeldr\arch\i386\xboxmem.c" line="50" id="uninitstring" severity="error" msg="Dangerous usage of 'ControlRegion' (not 0-terminated)"
file="reactos\boot\freeldr\freeldr\arch\powerpc\loader.c" line="142" id="nullPointer" severity="error" msg="Possible null pointer dereference: Function - otherwise it is redundant to check if Function is null at line 140"
file="reactos\boot\freeldr\freeldr\arch\powerpc\loader.c" line="172" id="nullPointer" severity="error" msg="Possible null pointer dereference: Function - otherwise it is redundant to check if Function is null at line 170"
file="reactos\boot\freeldr\freeldr\arch\powerpc\prep_ide.c" line="105" id="uninitstring" severity="error" msg="Dangerous usage of 'namebuf' (strncpy doesn't always 0-terminate it)"
file="reactos\dll\3rdparty\libjpeg\wrjpgcom.c" line="456" id="nullPointer" severity="error" msg="Possible null pointer dereference: comment_arg - otherwise it is redundant to check if comment_arg is null at line 454"
file="reactos\dll\3rdparty\libjpeg\wrjpgcom.c" line="583" id="memleak" severity="error" msg="Memory leak: comment_arg"
file="reactos\dll\3rdparty\libpng\pngrtran.c" line="1950" id="cppcheckError" severity="error" msg="Analysis failed. If the code is valid then please report this failure."
file="reactos\dll\3rdparty\libpng\pngrtran.c" line="1941" id="cppcheckError" severity="error" msg="Analysis failed. If the code is valid then please report this failure."
file="reactos\dll\3rdparty\libpng\pngrtran.c" line="1916" id="cppcheckError" severity="error" msg="Analysis failed. If the code is valid then please report this failure."
file="reactos\dll\3rdparty\libpng\pngrtran.c" line="1946" id="cppcheckError" severity="error" msg="Analysis failed. If the code is valid then please report this failure."
file="reactos\dll\3rdparty\libpng\pngrtran.c" line="1932" id="cppcheckError" severity="error" msg="Analysis failed. If the code is valid then please report this failure."
file="reactos\dll\3rdparty\libpng\pngrtran.c" line="1921" id="cppcheckError" severity="error" msg="Analysis failed. If the code is valid then please report this failure."
file="reactos\dll\3rdparty\libtiff\tif_ojpeg.c" line="639" id="syntaxError" severity="error" msg="syntax error"
file="reactos\dll\3rdparty\libxslt\attributes.c" line="666" id="nullPointer" severity="error" msg="Possible null pointer dereference: comp - otherwise it is redundant to check if comp is null at line 681"
file="reactos\dll\3rdparty\libxslt\transform.c" line="4251" id="nullPointer" severity="error" msg="Possible null pointer dereference: comp - otherwise it is redundant to check if comp is null at line 4232"
file="reactos\dll\3rdparty\libxslt\transform.c" line="4418" id="nullPointer" severity="error" msg="Possible null pointer dereference: comp - otherwise it is redundant to check if comp is null at line 4399"
file="reactos\dll\3rdparty\libxslt\transform.c" line="5324" id="nullPointer" severity="error" msg="Possible null pointer dereference: comp - otherwise it is redundant to check if comp is null at line 5303"
file="reactos\dll\3rdparty\libxslt\xslt.c" line="4369" id="nullPointer" severity="error" msg="Possible null pointer dereference: cctxt - otherwise it is redundant to check if cctxt is null at line 4366"
file="reactos\dll\3rdparty\mesa32\src\main\dlist.c" line="8231" id="nullPointer" severity="error" msg="Possible null pointer dereference: n - otherwise it is redundant to check if n is null at line 8227"
file="reactos\dll\3rdparty\mesa32\src\shader\atifragshader.c" line="293" id="nullPointer" severity="error" msg="Possible null pointer dereference: prog - otherwise it is redundant to check if prog is null at line 283"
file="reactos\dll\3rdparty\mesa32\src\shader\slang\slang_codegen.c" line="3828" id="nullPointer" severity="error" msg="Possible null pointer dereference: n - otherwise it is redundant to check if n is null at line 3820"
file="reactos\dll\3rdparty\mesa32\src\shader\slang\slang_link.c" line="136" id="memleak" severity="error" msg="Memory leak: map"
file="reactos\dll\cpl\desk\general.c" line="38" id="sprintfOverlappingData" severity="error" msg="The variable 'Desc' is used both as a parameter and as a destination in s[n]printf(). The origin and destination buffers overlap. Quote from glibc (C-library) documentation (http://www.gnu.org/software/libc/manual ... -Functions): 'If copying takes place between objects that overlap as a result of a call to sprintf() or snprintf(), the results are undefined.'"
file="reactos\dll\directx\ksproxy\proxy.cpp" line="978" id="nullPointer" severity="error" msg="Possible null pointer dereference: pFormat - otherwise it is redundant to check if pFormat is null at line 983"
file="reactos\dll\win32\advpack\files.c" line="47" id="AssignmentAddressToInteger" severity="portability" msg="Assigning an address value to the integer (int/long/etc) type is not portable across different platforms and compilers. For example in 32-bit Windows and linux they are same width, but in 64-bit Windows and linux they are of different width. In worst case you end up assigning 64-bit address to 32-bit integer. The safe way is to always assign addresses only to pointer types (or typedefs)."
file="reactos\dll\win32\comctl32\listview.c" line="4165" id="nullPointer" severity="error" msg="Possible null pointer dereference: lpItem - otherwise it is redundant to check if lpItem is null at line 4182"
file="reactos\dll\win32\comdlg32\filedlg31.c" line="711" id="AssignmentAddressToInteger" severity="portability" msg="Assigning an address value to the integer (int/long/etc) type is not portable across different platforms and compilers. For example in 32-bit Windows and linux they are same width, but in 64-bit Windows and linux they are of different width. In worst case you end up assigning 64-bit address to 32-bit integer. The safe way is to always assign addresses only to pointer types (or typedefs)."
file="reactos\dll\win32\dbghelp\regex.c" line="1986" id="memleak" severity="error" msg="Memory leak: compile_stack.stack"
file="reactos\dll\win32\dbghelp\regex.c" line="5754" id="memleak" severity="error" msg="Memory leak: regs.start"
file="reactos\dll\win32\dbghelp\regex.c" line="5754" id="memleak" severity="error" msg="Memory leak: regs.end"
file="reactos\dll\win32\dbghelp\regex.c" line="1998" id="memleak" severity="error" msg="Memory leak: compile_stack.stack"
file="reactos\dll\win32\glu32\libnurbs\internals\curvelist.h" line="63" id="memleak" severity="error" msg="Memory leak: Curvelist::curve"
file="reactos\dll\win32\glu32\libnurbs\internals\patchlist.h" line="69" id="memleak" severity="error" msg="Memory leak: Patchlist::patch"
file="reactos\dll\win32\glu32\libnurbs\internals\tobezier.cc" line="100" id="memleak" severity="error" msg="Memory leak: Splinespec::kspec"
file="reactos\dll\win32\glu32\libnurbs\internals\tobezier.cc" line="102" id="memleak" severity="error" msg="Memory leak: Splinespec::outcpts"
file="reactos\dll\win32\glu32\libutil\mipmap.c" line="6611" id="syntaxError" severity="error" msg="Invalid number of character (() when these macros are defined: 'RESOLVE_3D_TEXTURE_SUPPORT'."
file="reactos\dll\win32\kernel32\client\debugger.c" line="888" id="nullPointer" severity="error" msg="Possible null pointer dereference: a_cBuffer - otherwise it is redundant to check if a_cBuffer is null at line 893"
file="reactos\dll\win32\kernel32\client\loader.c" line="439" id="cppcheckError" severity="error" msg="Analysis failed. If the code is valid then please report this failure."
file="reactos\dll\win32\kernel32\wine\res.c" line="365" id="cppcheckError" severity="error" msg="Analysis failed. If the code is valid then please report this failure."
file="reactos\dll\win32\shdocvw\intshcut.c" line="641" id="syntaxError" severity="error" msg="syntax error"
file="reactos\dll\win32\twain_32\dsm_ctrl.c" line="149" id="uninitvar" severity="error" msg="Uninitialized variable: pSourceIdentity"
file="reactos\dll\win32\twain_32\dsm_ctrl.c" line="150" id="uninitvar" severity="error" msg="Uninitialized variable: pSourceIdentity"
file="reactos\dll\win32\user32\misc\ddeserver.c" line="387" id="nullPointer" severity="error" msg="Possible null pointer dereference: pInstance - otherwise it is redundant to check if pInstance is null at line 388"
file="reactos\dll\win32\winhttp\inet_ntop.c" line="93" id="uninitvar" severity="error" msg="Uninitialized variable: tmp"
file="reactos\dll\win32\wininet\inet_ntop.c" line="91" id="uninitvar" severity="error" msg="Uninitialized variable: tmp"
file="reactos\dll\win32\ws2_32\misc\ns.c" line="686" id="nullPointer" severity="error" msg="Possible null pointer dereference: s - otherwise it is redundant to check if s is null at line 691"
file="reactos\dll\win32\ws2_32\misc\ns.c" line="687" id="nullPointer" severity="error" msg="Possible null pointer dereference: s - otherwise it is redundant to check if s is null at line 691"
file="reactos\dll\win32\ws2_32\misc\ns.c" line="689" id="nullPointer" severity="error" msg="Possible null pointer dereference: s - otherwise it is redundant to check if s is null at line 691"
file="reactos\dll\win32\ws2_32\misc\ns.c" line="690" id="nullPointer" severity="error" msg="Possible null pointer dereference: s - otherwise it is redundant to check if s is null at line 691"
file="reactos\drivers\bus\acpi\acpica\events\evregion.c" line="661" id="nullPointer" severity="error" msg="Possible null pointer dereference: HandlerObj - otherwise it is redundant to check if HandlerObj is null at line 652"
file="reactos\drivers\bus\acpi\acpica\executer\exresolv.c" line="548" id="nullPointer" severity="error" msg="Possible null pointer dereference: ObjDesc - otherwise it is redundant to check if ObjDesc is null at line 549"
file="reactos\drivers\bus\acpi\acpica\namespace\nsalloc.c" line="416" id="nullPointer" severity="error" msg="Possible null pointer dereference: ParentNode - otherwise it is redundant to check if ParentNode is null at line 409"
file="reactos\drivers\bus\acpi\acpica\parser\psscope.c" line="366" id="nullPointer" severity="error" msg="Possible null pointer dereference: ParserState - otherwise it is redundant to check if ParserState is null at line 359"
file="reactos\drivers\bus\acpi\busmgr\bus.c" line="733" id="nullPointer" severity="error" msg="Possible null pointer dereference: device"
file="reactos\drivers\bus\acpi\busmgr\bus.c" line="743" id="nullPointer" severity="error" msg="Possible null pointer dereference: device"
file="reactos\drivers\bus\acpi\busmgr\bus.c" line="753" id="nullPointer" severity="error" msg="Possible null pointer dereference: device"
file="reactos\drivers\bus\acpi\busmgr\bus.c" line="763" id="nullPointer" severity="error" msg="Possible null pointer dereference: device"
file="reactos\drivers\bus\acpi\busmgr\bus.c" line="769" id="nullPointer" severity="error" msg="Possible null pointer dereference: device"
file="reactos\drivers\bus\acpi\busmgr\bus.c" line="775" id="nullPointer" severity="error" msg="Possible null pointer dereference: device"
file="reactos\drivers\bus\acpi\busmgr\bus.c" line="781" id="nullPointer" severity="error" msg="Possible null pointer dereference: device"
file="reactos\drivers\bus\acpi\busmgr\bus.c" line="787" id="nullPointer" severity="error" msg="Possible null pointer dereference: device"
file="reactos\drivers\bus\acpi\cmbatt\cmbatt.c" line="933" id="udivError" severity="error" msg="Unsigned division. The result will be wrong."
file="reactos\drivers\ksfilter\ks\swenum.c" line="1388" id="nullPointer" severity="error" msg="Possible null pointer dereference: BusDeviceExtension - otherwise it is redundant to check if BusDeviceExtension is null at line 1390"
file="reactos\drivers\storage\ide\uniata\id_ata.cpp" line="1280" id="nullPointer" severity="error" msg="Possible null pointer dereference: chan - otherwise it is redundant to check if chan is null at line 1302"
file="reactos\drivers\storage\ide\uniata\id_ata.cpp" line="1282" id="nullPointer" severity="error" msg="Possible null pointer dereference: chan - otherwise it is redundant to check if chan is null at line 1302"
file="reactos\drivers\storage\ide\uniata\id_ata.cpp" line="6929" id="nullPointer" severity="error" msg="Possible null pointer dereference: chan - otherwise it is redundant to check if chan is null at line 6931"
file="reactos\drivers\storage\ide\uniata\id_ata.cpp" line="6902" id="bufferAccessOutOfBounds" severity="error" msg="Buffer access out-of-bounds: inquiryData.VendorId"
file="reactos\drivers\storage\ide\uniata\id_dma.cpp" line="826" id="nullPointer" severity="error" msg="Possible null pointer dereference: chan - otherwise it is redundant to check if chan is null at line 891"
file="reactos\drivers\storage\ide\uniata\id_probe.cpp" line="2743" id="nullPointer" severity="error" msg="Possible null pointer dereference: chan - otherwise it is redundant to check if chan is null at line 2755"
file="reactos\drivers\storage\ide\uniata\id_probe.cpp" line="2835" id="nullPointer" severity="error" msg="Possible null pointer dereference: chan - otherwise it is redundant to check if chan is null at line 2868"
file="reactos\drivers\storage\ide\uniata\id_probe.cpp" line="3090" id="nullPointer" severity="error" msg="Possible null pointer dereference: chan - otherwise it is redundant to check if chan is null at line 3162"
file="reactos\drivers\storage\ide\uniata\id_probe.cpp" line="3099" id="nullPointer" severity="error" msg="Possible null pointer dereference: chan - otherwise it is redundant to check if chan is null at line 3162"
file="reactos\drivers\storage\ide\uniata\id_probe.cpp" line="918" id="syntaxError" severity="error" msg="Invalid number of character ({) when these macros are defined: 'UNIATA_CORE'."
file="reactos\drivers\usb\nt4compat\usbdrv\ehci.c" line="1021" id="nullPointer" severity="error" msg="Possible null pointer dereference: ptdc"
file="reactos\drivers\usb\nt4compat\usbdrv\td.c" line="188" id="nullPointer" severity="error" msg="Possible null pointer dereference: ptd_pool - otherwise it is redundant to check if ptd_pool is null at line 191"
file="reactos\drivers\wdm\audio\drivers\CMIDriver\adapter.cpp" line="258" id="nullPointer" severity="error" msg="Possible null pointer dereference: pCMIAdapter - otherwise it is redundant to check if pCMIAdapter is null at line 343"
file="reactos\drivers\wdm\audio\drivers\CMIDriver\cmicontrol\main.cpp" line="243" id="nullPointer" severity="error" msg="Possible null pointer dereference: ds - otherwise it is redundant to check if ds is null at line 250"
file="reactos\drivers\wdm\audio\drivers\CMIDriver\cmicontrol\main.cpp" line="245" id="nullPointer" severity="error" msg="Possible null pointer dereference: ds - otherwise it is redundant to check if ds is null at line 250"
file="reactos\drivers\wdm\audio\drivers\CMIDriver\cmicontrol\main.cpp" line="290" id="nullPointer" severity="error" msg="Possible null pointer dereference: ds - otherwise it is redundant to check if ds is null at line 295"
file="reactos\drivers\wdm\audio\legacy\wdmaud\sup.c" line="379" id="nullPointer" severity="error" msg="Possible null pointer dereference: Device - otherwise it is redundant to check if Device is null at line 380"
file="reactos\include\c++\stlport\stl\_list.c" line="140" id="syntaxError" severity="error" msg="syntax error"
file="reactos\lib\3rdparty\adns\client\adnslogres.c" line="114" id="negativeIndex" severity="error" msg="Array index -1 is out of bounds"
file="reactos\lib\3rdparty\adns\client\adnslogres.c" line="115" id="negativeIndex" severity="error" msg="Array index -1 is out of bounds"
file="reactos\lib\3rdparty\bzip2\bzip2recover.c" line="312" id="insecureCmdLineArgs" severity="error" msg="Buffer overrun possible for long cmd-line args"
file="reactos\lib\3rdparty\bzip2\bzip2recover.c" line="425" id="resourceLeak" severity="error" msg="Resource leak: inFile"
file="reactos\lib\3rdparty\bzip2\bzip2recover.c" line="508" id="resourceLeak" severity="error" msg="Resource leak: outFile"
file="reactos\lib\3rdparty\bzip2\unzcrash.c" line="141" id="resourceLeak" severity="error" msg="Resource leak: f"
file="reactos\lib\3rdparty\expat\lib\xmlparse.c" line="1500" id="AssignmentAddressToInteger" severity="portability" msg="Assigning an address value to the integer (int/long/etc) type is not portable across different platforms and compilers. For example in 32-bit Windows and linux they are same width, but in 64-bit Windows and linux they are of different width. In worst case you end up assigning 64-bit address to 32-bit integer. The safe way is to always assign addresses only to pointer types (or typedefs)."
file="reactos\lib\3rdparty\freetype\src\base\ftdbgmem.c" line="349" id="nullPointer" severity="error" msg="Possible null pointer dereference: table - otherwise it is redundant to check if table is null at line 351"
file="reactos\lib\3rdparty\freetype\src\gxvalid\gxvmort.c" line="204" id="nullPointer" severity="error" msg="Possible null pointer dereference: func - otherwise it is redundant to check if func is null at line 201"
file="reactos\lib\3rdparty\freetype\src\gxvalid\gxvmorx.c" line="98" id="nullPointer" severity="error" msg="Possible null pointer dereference: func - otherwise it is redundant to check if func is null at line 95"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="1930" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="1942" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="1964" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="1975" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="2009" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="2050" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="2094" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="2136" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="2180" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="2224" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="2538" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="2565" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="2726" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="4414" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="4517" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="4634" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="5463" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="5674" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="6299" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="6471" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="6742" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\freetype\src\truetype\ttinterp.c" line="7058" id="uninitvar" severity="error" msg="Uninitialized variable: __dummy"
file="reactos\lib\3rdparty\libmpg123\icy2utf8.c" line="428" id="memleak" severity="error" msg="Memory leak: t"
file="reactos\lib\3rdparty\libmpg123\lfs_wrap.c" line="366" id="nullPointer" severity="error" msg="Possible null pointer dereference: fill - otherwise it is redundant to check if fill is null at line 363"
file="reactos\lib\3rdparty\libxml2\catalog.c" line="996" id="resourceLeak" severity="error" msg="Resource leak: fd"
file="reactos\lib\3rdparty\libxml2\runtest.c" line="1686" id="memleak" severity="error" msg="Memory leak: temp"
file="reactos\lib\3rdparty\libxml2\xmlmemory.c" line="583" id="nullPointer" severity="error" msg="Possible null pointer dereference: p - otherwise it is redundant to check if p is null at line 586"
file="reactos\lib\3rdparty\libxml2\xmlregexp.c" line="5695" id="nullPointer" severity="error" msg="Possible null pointer dereference: atom - otherwise it is redundant to check if atom is null at line 5696"
file="reactos\lib\3rdparty\libxml2\xmlschemas.c" line="25206" id="nullPointer" severity="error" msg="Possible null pointer dereference: attrUseList - otherwise it is redundant to check if attrUseList is null at line 25200"
file="reactos\lib\3rdparty\libxml2\xmlschemastypes.c" line="1568" id="syntaxError" severity="error" msg="syntax error"
file="reactos\lib\3rdparty\stlport\test\unit\ctype_facets_test.cpp" line="212" id="arrayIndexOutOfBounds" severity="error" msg="Array 'res[3]' index 4 out of bounds"
file="reactos\lib\3rdparty\stlport\test\unit\ctype_facets_test.cpp" line="213" id="arrayIndexOutOfBounds" severity="error" msg="Array 'res[3]' index 4 out of bounds"
file="reactos\lib\3rdparty\stlport\test\unit\ctype_facets_test.cpp" line="214" id="arrayIndexOutOfBounds" severity="error" msg="Array 'res[3]' index 4 out of bounds"
file="reactos\lib\3rdparty\stlport\test\unit\deque_test.cpp" line="77" id="stlBoundries" severity="error" msg="Container 'deque' iterator compared with < operator. Using < operator with container type iterators is dangerous since the order of the items is not guaranteed. One should use != operator instead when comparing iterators in the container."
file="reactos\lib\3rdparty\stlport\test\unit\strstream_test.cpp" line="32" id="syntaxError" severity="error" msg="Invalid number of character ({) when these macros are defined: ''."
file="reactos\lib\drivers\lwip\src\api\api_msg.c" line="225" id="nullPointer" severity="error" msg="Possible null pointer dereference: conn - otherwise it is redundant to check if conn is null at line 227"
file="reactos\lib\drivers\lwip\src\api\api_msg.c" line="320" id="nullPointer" severity="error" msg="Possible null pointer dereference: conn - otherwise it is redundant to check if conn is null at line 326"
file="reactos\lib\drivers\lwip\src\api\api_msg.c" line="322" id="nullPointer" severity="error" msg="Possible null pointer dereference: conn - otherwise it is redundant to check if conn is null at line 326"
file="reactos\lib\drivers\lwip\src\core\ipv4\igmp.c" line="813" id="nullPointer" severity="error" msg="Possible null pointer dereference: igmp"
file="reactos\lib\sdk\crt\float\i386\statfp.c" line="35" id="uninitvar" severity="error" msg="Uninitialized variable: fpword"
file="reactos\lib\sdk\crt\math\j0_y0.c" line="29" id="wrongmathcall" severity="error" msg="Passing value -1 to sqrt() leads to undefined result"
file="reactos\lib\sdk\crt\math\j1_y1.c" line="29" id="wrongmathcall" severity="error" msg="Passing value -1 to sqrt() leads to undefined result"
file="reactos\lib\sdk\crt\math\jn_yn.c" line="29" id="wrongmathcall" severity="error" msg="Passing value -1 to sqrt() leads to undefined result"
file="reactos\ntoskrnl\cache\section\sptab.c" line="120" id="nullPointer" severity="error" msg="Possible null pointer dereference: PageTableSlice - otherwise it is redundant to check if PageTableSlice is null at line 121"
file="reactos\ntoskrnl\kdbg\amd64\i386-dis.c" line="3017" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\amd64\i386-dis.c" line="3022" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\amd64\i386-dis.c" line="3027" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\amd64\i386-dis.c" line="3032" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\amd64\i386-dis.c" line="3037" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\amd64\i386-dis.c" line="3042" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\amd64\i386-dis.c" line="3959" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\i386\i386-dis.c" line="3015" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\i386\i386-dis.c" line="3020" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\i386\i386-dis.c" line="3025" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\i386\i386-dis.c" line="3030" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\i386\i386-dis.c" line="3035" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\i386\i386-dis.c" line="3040" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\ntoskrnl\kdbg\i386\i386-dis.c" line="3952" id="strPlusChar" severity="error" msg="Unusual pointer arithmetic"
file="reactos\subsystems\ntvdm\ntvdm.c" line="311" id="bufferAccessOutOfBounds" severity="error" msg="Buffer access out-of-bounds"
file="reactos\tools\cabman\cabinet.cxx" line="2058" id="memleak" severity="error" msg="Memory leak: FileNode"
file="reactos\tools\cabman\cabinet.cxx" line="2625" id="memleak" severity="error" msg="Memory leak: Node"
file="reactos\tools\rbuild\module.cpp" line="50" id="nullPointer" severity="error" msg="Possible null pointer dereference: p - otherwise it is redundant to check if p is null at line 40"
Enjoy with it ;)

Heis Spiter
Posts: 183
Joined: Sun Sep 03, 2006 11:39 am
Location: Paris, France
Contact:

Re: CppCheck report

Post by Heis Spiter » Tue Nov 29, 2011 11:13 pm

Hi,

just for the record: http://fezile.reactos.org/cppcheck/

Regards,
Pierre
Pierre Schweitzer (aka Heis Spiter)
ReactOS kernel developer.
ReactOS systems administrator.

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests