Wireshark-dev: [Wireshark-dev] LUA/PCRE Warnings when building on Windows + preferences?

From: Anders Broman <a.broman58@xxxxxxxxx>
Date: Mon, 30 May 2022 16:46:57 +0200
Hi,
I see these warnings building top of tree:
       "C:\Development\ewireshark\build\Wireshark.sln" (default target) (1) ->
       "C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj.metaproj" (default target) (47) ->
       "C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj" (default target) (114) ->
       (ClCompile target) ->
         C:\Development\ewireshark\source\epan\wslua\lrexlib\common.c(46,9): warning C4244: '=': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\common.c(46,9): warning C4244:   val = lua_tointeger (L, -1); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\common.c(46,9): warning C4244:         ^ [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(76,13): warning C4244: 'initializing': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(76,13): warning C4244:     int a = lua_tointeger (L, pos); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(76,13): warning C4244:             ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(88,23): warning C4267: '+=': conversion from 'size_t' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(88,23): warning C4267:     startoffset += len/ALG_CHARSIZE; [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(88,23): warning C4267:                       ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(315,30): warning C4267: 'function': conversion from 'size_t' to 'uint32_t', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(315,30): warning C4267:         else if (num == 0 || ALG_SUBVALID (ud,num)) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(315,30): warning C4267:                              ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(389,17): warning C4244: 'initializing': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(389,17): warning C4244:         int n = lua_tointeger (L, -1); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(389,17): warning C4244:                 ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(536,22): warning C4244: '=': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(536,22): warning C4244:   argE.eflags      = lua_tointeger (L, lua_upvalueindex (3)); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(536,22): warning C4244:                      ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(537,22): warning C4244: '=': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(537,22): warning C4244:   argE.startoffset = lua_tointeger (L, lua_upvalueindex (4)); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(537,22): warning C4244:                      ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(538,22): warning C4244: '=': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(538,22): warning C4244:   last_end         = lua_tointeger (L, lua_upvalueindex (5)); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(538,22): warning C4244:                      ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(581,22): warning C4244: '=': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(581,22): warning C4244:   argE.eflags      = lua_tointeger (L, lua_upvalueindex (3)); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(581,22): warning C4244:                      ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(582,22): warning C4244: '=': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(582,22): warning C4244:   argE.startoffset = lua_tointeger (L, lua_upvalueindex (4)); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(582,22): warning C4244:                      ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(583,22): warning C4244: '=': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(583,22): warning C4244:   incr             = lua_tointeger (L, lua_upvalueindex (5)); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(583,22): warning C4244:                      ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(584,22): warning C4244: '=': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(584,22): warning C4244:   last_end         = lua_tointeger (L, lua_upvalueindex (6)); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\../algo.h(584,22): warning C4244:                      ^ (compiling source file C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(138,14): warning C4244: 'return': conversion from 'lua_Integer' to 'int', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(138,14): warning C4244:       return lua_tointeger (L, pos); [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(138,14): warning C4244:              ^ [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(325,57): warning C4267: 'function': conversion from 'size_t' to 'uint32_t', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(325,57): warning C4267:   ud->match_data = pcre2_match_data_create(argE.ovecsize/2, NULL); //### CHECK ALL [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(325,57): warning C4267:                                                         ^ [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(445,3): warning C4244: 'function': conversion from 'size_t' to 'lua_Number', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(445,3): warning C4244:   SET_INFO_FIELD (L, ud, PCRE2_INFO_JITSIZE,             "JITSIZE",             size_t) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(445,3): warning C4244:   ^ [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
         C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(457,3): warning C4244: 'function': conversion from 'size_t' to 'lua_Number', possible loss of data [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(457,3): warning C4244:   SET_INFO_FIELD (L, ud, PCRE2_INFO_SIZE,                "SIZE",                size_t) [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]
       C:\Development\ewireshark\source\epan\wslua\lrexlib\pcre2\lpcre2.c(457,3): warning C4244:   ^ [C:\Development\ewireshark\build\epan\wslua\lrexlib\lrexlib.vcxproj]


       "C:\Development\ewireshark\build\Wireshark.sln" (default target) (1) ->
       "C:\Development\ewireshark\build\copy_data_files.vcxproj.metaproj" (default target) (13) ->
       "C:\Development\ewireshark\build\copy_data_files.vcxproj" (default target) (118) ->
       (CustomBuild target) ->
         C:\Program Files\Microsoft Visual Studio\2022\Enterprise\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(245,5): warning MSB8065: Custom build for item "C:\Development\ewireshark\build\CMakeFiles\27160bb87813d695fa2b709427944ac5\colorfilters.rule" succeeded, but specified output "c:\development\ewireshark\build\run\relwithdebinfo\resources\share\wireshark\profiles\bluetooth\colorfilters" has not been created. This may cause incremental build to work incorrectly. [C:\Development\ewireshark\build\copy_data_files.vcxproj]
         C:\Program Files\Microsoft Visual Studio\2022\Enterprise\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(245,5): warning MSB8065: Custom build for item "C:\Development\ewireshark\build\CMakeFiles\27160bb87813d695fa2b709427944ac5\colorfilters.rule" succeeded, but specified output "c:\development\ewireshark\build\run\relwithdebinfo\resources\share\wireshark\profiles\bluetooth\preferences" has not been created. This may cause incremental build to work incorrectly. [C:\Development\ewireshark\build\copy_data_files.vcxproj]
         C:\Program Files\Microsoft Visual Studio\2022\Enterprise\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(245,5): warning MSB8065: Custom build for item "C:\Development\ewireshark\build\CMakeFiles\27160bb87813d695fa2b709427944ac5\colorfilters.rule" succeeded, but specified output "c:\development\ewireshark\build\run\relwithdebinfo\resources\share\wireshark\profiles\classic\colorfilters" has not been created. This may cause incremental build to work incorrectly. [C:\Development\ewireshark\build\copy_data_files.vcxproj]
         C:\Program Files\Microsoft Visual Studio\2022\Enterprise\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(245,5): warning MSB8065: Custom build for item "C:\Development\ewireshark\build\CMakeFiles\27160bb87813d695fa2b709427944ac5\colorfilters.rule" succeeded, but specified output "c:\development\ewireshark\build\run\relwithdebinfo\resources\share\wireshark\profiles\no reassembly\preferences" has not been created. This may cause incremental build to work incorrectly. [C:\Development\ewireshark\build\copy_data_files.vcxproj]

    20 Warning(s)
    0 Error(s)