Project

General

Profile

Actions

Bug #2493

open

‘unique_ipaddr’ may be used uninitialized

Added by Marko Lindqvist 8 days ago. Updated 6 days ago.

Status:
In Review
Priority:
Normal
Category:
Server
Target version:
Start date:
11/16/2026
Due date:
% Done:

0%

Estimated time:

Description

S3_2 build with O3 optimization level on ubuntu-27.04 development version:

FAILED: [code=1] libfc_server.a.p/server_stdinhand.c.o 
cc -Ilibfc_server.a.p -I. -I../../src -I../../src/dependencies/luasql/src -I../../src/dependencies/tinycthread -I../../src/dependencies/tolua-5.2/include -I../../src/dependencies/cvercmp -I../../src/utility -I../../src/common -I../../src/common/networking -I../../src/common/scriptcore -I../../src/common/aicore -I../../src/server -I../../src/server/advisors -I../../src/server/scripting -I../../src/server/generator -I../../src/server/savegame -I../../src/ai -I../../src/ai/classic -I/usr/include/lua5.4 -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Werror -O3 -g -Wno-nonnull-compare -Wnested-externs -Wmissing-declarations -Wpointer-arith -Wcast-align -Wmissing-prototypes -Wformat -Wformat-security -Wshadow -Wold-style-declaration -Wold-style-definition -Wtype-limits -Wimplicit-fallthrough -DHAVE_CONFIG_H -fPIC -MD -MQ libfc_server.a.p/server_stdinhand.c.o -MF libfc_server.a.p/server_stdinhand.c.o.d -o libfc_server.a.p/server_stdinhand.c.o -c ../../src/server/stdinhand.c
In function ‘kick_command’,
    inlined from ‘handle_stdin_input_real’ at ../../src/server/stdinhand.c:4727:12:
../../src/server/stdinhand.c:6373:18: error: ‘unique_ipaddr’ may be used uninitialized [-Werror=maybe-uninitialized]
 6373 |         if (0 == strcmp(unique_ipaddr[i], aconn->server.ipaddr)) {
      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../src/server/stdinhand.c: In function ‘handle_stdin_input_real’:
../../src/server/stdinhand.c:6363:17: note: ‘unique_ipaddr’ declared here
 6363 |     const char *unique_ipaddr[MIN_UNIQUE_CONNS];
      |                 ^~~~~~~~~~~~~
cc1: all warnings being treated as errors


Files


Related issues 2 (2 open — 0 closed)

Blocks Task #2401: Release 3.2.8New10/21/2026

Actions
Blocks Task #2190: Release 3.3.0-beta1NewMarko Lindqvist08/31/2026

Actions
Actions #1

Updated by Marko Lindqvist 8 days ago

Actions #2

Updated by Marko Lindqvist 8 days ago

Actions

Also available in: Atom PDF