﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	resolution	keywords	cc	phab_field
5294	GCC 8 compiler warnings	elexis	Alex	"When I compile 0ad with gcc 8.1.0, I get the following warnings:
{{{
====================================================================================================================================================================================

In file included from ../../../source/pch/atlas/precompiled.h:24:
../../../source/tools/atlas/GameInterface/Messages.h: In function ‘void AtlasMessage::fGetTerrainGroupPreviews(AtlasMessage::qGetTerrainGroupPreviews*)’:
../../../source/tools/atlas/GameInterface/Messages.h:292:8: warning: ‘#‘target_mem_ref’ not supported by dump_expr#<expression error>’ may be used uninitialized in this function [-Wmaybe-uninitialized]
 struct sTerrainTexturePreview
        ^~~~~~~~~~~~~~~~~~~~~~
../../../source/tools/atlas/GameInterface/Messages.h:292:8: warning: ‘#‘target_mem_ref’ not supported by dump_expr#<expression error>’ may be used uninitialized in this function [-Wmaybe-uninitialized]
../../../source/tools/atlas/GameInterface/Messages.h:292:8: warning: ‘#‘target_mem_ref’ not supported by dump_expr#<expression error>’ may be used uninitialized in this function [-Wmaybe-uninitialized]
../../../source/tools/atlas/GameInterface/Messages.h:292:8: warning: ‘#‘target_mem_ref’ not supported by dump_expr#<expression error>’ may be used uninitialized in this function [-Wmaybe-uninitialized]
 struct sTerrainTexturePreview
        ^~~~~~~~~~~~~~~~~~~~~~
../../../source/tools/atlas/GameInterface/Messages.h:292:8: warning: ‘#‘target_mem_ref’ not supported by dump_expr#<expression error>’ may be used uninitialized in this function [-Wmaybe-uninitialized]
../../../source/tools/atlas/GameInterface/Messages.h:292:8: warning: ‘#‘target_mem_ref’ not supported by dump_expr#<expression error>’ may be used uninitialized in this function [-Wmaybe-uninitialized]

====================================================================================================================================================================================

../../../source/lib/res/h_mgr.cpp: In function ‘void h_free_hd(HDATA*)’:
../../../source/lib/res/h_mgr.cpp:578:27: warning: ‘void* memset(void*, int, size_t)’ clearing an object of type ‘struct HDATA’ with no trivial copy-assignment; use assignment or value-initialization instead [-Wclass-memaccess]
  memset(hd, 0, sizeof(*hd));
                           ^
../../../source/lib/res/h_mgr.cpp:140:8: note: ‘struct HDATA’ declared here
 struct HDATA
        ^~~~~

====================================================================================================================================================================================

../../../source/third_party/mongoose/mongoose.cpp: In function ‘mg_context* mg_start(mg_callback_t, void*, const char**)’:
../../../source/third_party/mongoose/mongoose.cpp:4297:40: warning: cast between incompatible function types from ‘void (*)(mg_context*)’ to ‘mg_thread_func_t’ {aka ‘void* (*)(void*)’} [-Wcast-function-type]
   start_thread(ctx, (mg_thread_func_t) master_thread, ctx);
                                        ^~~~~~~~~~~~~
../../../source/third_party/mongoose/mongoose.cpp:4301:46: warning: cast between incompatible function types from ‘void (*)(mg_context*)’ to ‘mg_thread_func_t’ {aka ‘void* (*)(void*)’} [-Wcast-function-type]
     if (start_thread(ctx, (mg_thread_func_t) worker_thread, ctx) != 0) {

====================================================================================================================================================================================

}}}"	defect	new	Should Have	Alpha 24	Core engine				Phab:D2055, Phab:D2099, Phab:D2102, Phab:D2153
