Skip to content
Binary file added Release/qstat.tlog/link.write.1.tlog
Binary file not shown.
2 changes: 2 additions & 0 deletions Release/qstat.tlog/qstat.lastbuildstate
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
PlatformToolSet=v143:VCToolArchitecture=Native32Bit:VCToolsVersion=14.31.31103:TargetPlatformVersion=10.0.19041.0:
Release|Win32|D:\Games\qstat-imago\|
Binary file added Release/qstat.tlog/qstat.write.1u.tlog
Binary file not shown.
1 change: 1 addition & 0 deletions Release/qstat.vcxproj.FileListAbsolute.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
D:\Games\qstat-imago\Release\qstat.exe
19 changes: 1 addition & 18 deletions config.c
Original file line number Diff line number Diff line change
Expand Up @@ -225,24 +225,7 @@ qsc_load_default_config_files()
strcpy(path, sysconfdir SEP CONFIG_FILE);
filename = path;
#elif defined(_WIN32)
// Look in the binaries directory
rc = GetModuleFileName(NULL, path, PATH_MAX);
if (rc == PATH_MAX) {
fprintf(stderr, "Module path too long\n");
return (1);
}
var = strrchr(path, '\\');
if (var == NULL) {
fprintf(stderr, "Unexpected module path \"%s\" (no seperator %s)\n", path, SEP);
return (-1);
}
*var = '\0';
if (strlen(path) >= PATH_MAX - 11) {
fprintf(stderr, "Module path \"%s\" too long\n", path);
return (-1);
}
strcat(path, SEP CONFIG_FILE);
filename = path;
filename = CONFIG_FILE;
#endif

if (filename != NULL) {
Expand Down
7 changes: 7 additions & 0 deletions md5.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,13 @@
*/
/* $Id$ */

# if defined(_MSC_VER)
# ifndef _CRT_SECURE_NO_DEPRECATE
# define _CRT_SECURE_NO_DEPRECATE (1)
# endif
# pragma warning(disable : 4996)
# endif

/*
* Independent implementation of MD5 (RFC 1321).
*
Expand Down
9 changes: 6 additions & 3 deletions qstat.c
Original file line number Diff line number Diff line change
Expand Up @@ -8462,6 +8462,7 @@ deal_with_tribes_packet(struct qserver *server, char *rawpkt, int pktlen)

len = *pkt; /* description (contains Admin: and Email: ) */
debug(2, "%.*s\n", len, pkt + 1);
add_nrule(server, "info", (char*)pkt + 1, len); //imago
pkt += len + 1;

n_teams = *pkt++; /* number of teams */
Expand Down Expand Up @@ -8539,9 +8540,11 @@ deal_with_tribes_packet(struct qserver *server, char *rawpkt, int pktlen)
debug(2, "player#%d, info <%.*s>\n", pnum, len, pkt + 1);
end = (unsigned char *)strchr((char *)pkt + 9, 0x9);
if (end) {
strncpy(buf, (char *)pkt + 9, end - (pkt + 9));
buf[end - (pkt + 9)] = '\0';
player->frags = atoi(buf);
//strncpy(buf, (char *)pkt + 9, end - (pkt + 9));
//buf[end - (pkt + 9)] = '\0';
char* pbuf = strtok(end, "\t"); //imago
//strncpy(buf, (char*)end + 3,)
player->frags = atoi(pbuf);
debug(2, "player#%d, score <%.*s>\n", pnum, (unsigned)(end - (pkt + 9)), pkt + 9);
}

Expand Down
7 changes: 7 additions & 0 deletions qstat.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,13 @@ typedef struct _server_type server_type;
#define GCC_FORMAT_PRINTF(a, b)
#endif

# if defined(_MSC_VER)
# ifndef _CRT_SECURE_NO_DEPRECATE
# define _CRT_SECURE_NO_DEPRECATE (1)
# endif
# pragma warning(disable : 4996)
# endif

typedef enum {
INPROGRESS = 0,
DONE_AUTO = 1,
Expand Down
31 changes: 31 additions & 0 deletions qstat.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.1.32210.238
MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "qstat", "qstat.vcxproj", "{58D7DD00-1398-4EE6-AF15-6668D9295A1E}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{58D7DD00-1398-4EE6-AF15-6668D9295A1E}.Debug|x64.ActiveCfg = Release|x64
{58D7DD00-1398-4EE6-AF15-6668D9295A1E}.Debug|x64.Build.0 = Release|x64
{58D7DD00-1398-4EE6-AF15-6668D9295A1E}.Debug|x86.ActiveCfg = Debug|Win32
{58D7DD00-1398-4EE6-AF15-6668D9295A1E}.Debug|x86.Build.0 = Debug|Win32
{58D7DD00-1398-4EE6-AF15-6668D9295A1E}.Release|x64.ActiveCfg = Release|x64
{58D7DD00-1398-4EE6-AF15-6668D9295A1E}.Release|x64.Build.0 = Release|x64
{58D7DD00-1398-4EE6-AF15-6668D9295A1E}.Release|x86.ActiveCfg = Release|Win32
{58D7DD00-1398-4EE6-AF15-6668D9295A1E}.Release|x86.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {A86657A5-39AC-4F55-B1BE-6CA6C7DA5056}
EndGlobalSection
EndGlobal
227 changes: 227 additions & 0 deletions qstat.vcxproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,227 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>16.0</VCProjectVersion>
<Keyword>Win32Proj</Keyword>
<ProjectGuid>{58d7dd00-1398-4ee6-af15-6668d9295a1e}</ProjectGuid>
<RootNamespace>qstat</RootNamespace>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<LinkIncremental>false</LinkIncremental>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>wsock32.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>wsock32.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<WarningLevel>Level1</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalLibraryDirectories>
</AdditionalLibraryDirectories>
<AdditionalDependencies>wsock32.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>wsock32.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="a2s.c" />
<ClCompile Include="armyops.c" />
<ClCompile Include="bfbc2.c" />
<ClCompile Include="config.c" />
<ClCompile Include="crysis.c" />
<ClCompile Include="cube2.c" />
<ClCompile Include="debug.c" />
<ClCompile Include="dirtybomb.c" />
<ClCompile Include="display_json.c" />
<ClCompile Include="doom3.c" />
<ClCompile Include="farmsim.c" />
<ClCompile Include="fl.c" />
<ClCompile Include="gps.c" />
<ClCompile Include="gs2.c" />
<ClCompile Include="gs3.c" />
<ClCompile Include="haze.c" />
<ClCompile Include="hcache.c" />
<ClCompile Include="ksp.c" />
<ClCompile Include="md5.c" />
<ClCompile Include="mumble.c" />
<ClCompile Include="ottd.c" />
<ClCompile Include="packet_manip.c" />
<ClCompile Include="qserver.c" />
<ClCompile Include="qstat.c" />
<ClCompile Include="starmade.c" />
<ClCompile Include="tee.c" />
<ClCompile Include="template.c" />
<ClCompile Include="terraria.c" />
<ClCompile Include="tf.c" />
<ClCompile Include="tm.c" />
<ClCompile Include="ts2.c" />
<ClCompile Include="ts3.c" />
<ClCompile Include="ut2004.c" />
<ClCompile Include="utils.c" />
<ClCompile Include="ventrilo.c" />
<ClCompile Include="wic.c" />
<ClCompile Include="xform.c" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="a2s.h" />
<ClInclude Include="armyops.h" />
<ClInclude Include="bfbc2.h" />
<ClInclude Include="config.h" />
<ClInclude Include="crysis.h" />
<ClInclude Include="cube2.h" />
<ClInclude Include="debug.h" />
<ClInclude Include="dirtybomb.h" />
<ClInclude Include="display_json.h" />
<ClInclude Include="doom3.h" />
<ClInclude Include="farmsim.h" />
<ClInclude Include="fl.h" />
<ClInclude Include="gps.h" />
<ClInclude Include="gs2.h" />
<ClInclude Include="gs3.h" />
<ClInclude Include="haze.h" />
<ClInclude Include="ksp.h" />
<ClInclude Include="md5.h" />
<ClInclude Include="mumble.h" />
<ClInclude Include="ottd.h" />
<ClInclude Include="packet_manip.h" />
<ClInclude Include="qserver.h" />
<ClInclude Include="qstat.h" />
<ClInclude Include="starmade.h" />
<ClInclude Include="tee.h" />
<ClInclude Include="terraria.h" />
<ClInclude Include="tf.h" />
<ClInclude Include="tm.h" />
<ClInclude Include="ts2.h" />
<ClInclude Include="ts3.h" />
<ClInclude Include="ut2004.h" />
<ClInclude Include="utils.h" />
<ClInclude Include="ventrilo.h" />
<ClInclude Include="version.h" />
<ClInclude Include="wic.h" />
<ClInclude Include="xform.h" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
7 changes: 7 additions & 0 deletions utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,13 @@
#include <stdint.h>
#endif

# if defined(_MSC_VER)
# ifndef _CRT_SECURE_NO_DEPRECATE
# define _CRT_SECURE_NO_DEPRECATE (1)
# endif
# pragma warning(disable : 4996)
# endif

char *str_replace(char *, char *, char *);

#endif
11 changes: 11 additions & 0 deletions x64/Release/qstat.exe.recipe
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<Project>
<ProjectOutputs>
<ProjectOutput>
<FullPath>D:\Games\qstat-imago\x64\Release\qstat.exe</FullPath>
</ProjectOutput>
</ProjectOutputs>
<ContentFiles />
<SatelliteDlls />
<NonRecipeFileRefs />
</Project>
Binary file added x64/Release/qstat.iobj
Binary file not shown.
Binary file added x64/Release/qstat.ipdb
Binary file not shown.
Loading