diff --git a/scripts/refactor_count.py b/scripts/refactor_count.py index ee0a2fe13..8fdec46e9 100644 --- a/scripts/refactor_count.py +++ b/scripts/refactor_count.py @@ -20,15 +20,16 @@ allowed_words = [] allowed_words += ["qsort"] # stdio / stdlib allowed_words += ["size_t", "cosf", "sinf", "asinf", "acosf", "atanf", "powf", "fabs", "rand", "powf", "fmod", "sqrtf"] # math.h +allowed_words += ["time_t", "time", "strftime", "localtime"] # time.h allowed_words += [ # system.h "int64", - "dbg_assert", "dbg_msg", "dbg_break", "dbg_logger_stdout", "dbg_logger_debugger", + "dbg_assert", "dbg_msg", "dbg_break", "dbg_logger_stdout", "dbg_logger_debugger", "dbg_logger_file", "mem_alloc", "mem_zero", "mem_free", "mem_copy", "mem_move", "mem_comp", "mem_stats", "total_allocations", "allocated", "thread_create", "thread_sleep", "lock_wait", "lock_create", "lock_release", "lock_destroy", "swap_endian", "io_open", "io_read", "io_read", "io_write", "io_flush", "io_close", "io_seek", "io_skip", "io_tell", "io_length", "str_comp", "str_length", "str_quickhash", "str_format", "str_copy", "str_comp_nocase", "str_sanitize", "str_append", "str_comp_num", "str_find_nocase", "str_sanitize_strong", "str_uppercase", "str_toint", "str_tofloat", - "str_utf8_encode", "str_utf8_rewind", "str_utf8_forward", "str_utf8_decode", + "str_utf8_encode", "str_utf8_rewind", "str_utf8_forward", "str_utf8_decode", "str_sanitize_cc", "str_skip_whitespaces", "fs_makedir", "fs_listdir", "fs_storage_path", "fs_is_dir", "net_init", "net_addr_comp", "net_host_lookup", "net_addr_str", "type", "port", "net_addr_from_str", "net_udp_create", "net_udp_send", "net_udp_recv", "net_udp_close", "net_socket_read_wait", @@ -40,7 +41,7 @@ allowed_words += ["vec2", "vec3", "vec4", "round", "clamp", "length", "dot", "no allowed_words += [ # tl "array", "sorted_array", "string", "all", "sort", "add", "remove_index", "remove", "delete_all", "set_size", - "base_ptr", "size", "swap", "empty", "front", "pop_front", "find_binary", "find_linear", "clear", "range", "end" + "base_ptr", "size", "swap", "empty", "front", "pop_front", "find_binary", "find_linear", "clear", "range", "end", "cstr", "partition_linear", "partition_binary"] allowed_words += ["fx2f", "f2fx"] # fixed point math diff --git a/src/engine/server/register.cpp b/src/engine/server/register.cpp index 5e49f4990..e9616ca17 100644 --- a/src/engine/server/register.cpp +++ b/src/engine/server/register.cpp @@ -120,11 +120,11 @@ void CRegister::RegisterUpdate() int i; for(i = 0; i < IMasterServer::MAX_MASTERSERVERS; i++) { - NETADDR addr = m_pMasterServer->GetAddr(i); - m_aMasterserverInfo[i].m_Addr = addr; + NETADDR Addr = m_pMasterServer->GetAddr(i); + m_aMasterserverInfo[i].m_Addr = Addr; m_aMasterserverInfo[i].m_Count = 0; - if(!addr.ip[0] && !addr.ip[1] && !addr.ip[2] && !addr.ip[3]) + if(!Addr.ip[0] && !Addr.ip[1] && !Addr.ip[2] && !Addr.ip[3]) m_aMasterserverInfo[i].m_Valid = 0; else { diff --git a/src/engine/shared/masterserver.cpp b/src/engine/shared/masterserver.cpp index beade5bf5..f10469bda 100644 --- a/src/engine/shared/masterserver.cpp +++ b/src/engine/shared/masterserver.cpp @@ -1,5 +1,5 @@ // copyright (c) 2007 magnus auvinen, see licence.txt for more info -#include +#include // sscanf #include #include