when I am on windows 10 and using PuTTY to SSH into my server start my server and watch the console output when some of these escaped hex shows up in console output PuTTY will freak out and when I go to quit or shutdown the server it will seg fault on linux
fails when \x05 is printed to server console
Code:
#include <sourcemod>
#include <sdktools>
#pragma semicolon 1
#pragma newdecls required
#define PLUGIN_VERSION "0.00"
public Plugin myinfo =
{
name = "HEX TEST",
author = "linux_canadajeff",
description = "Testing Print To Server To Find What Makes It Crash!!!!",
version = PLUGIN_VERSION,
url = ""
};
public void OnPluginStart()
{
CreateConVar("sm_hextest_version", PLUGIN_VERSION, "Standard plugin version ConVar. Please don't change me!", FCVAR_REPLICATED|FCVAR_NOTIFY|FCVAR_DONTRECORD);
RegAdminCmd("sm_hextest", hextest, ADMFLAG_ROOT, "Tests the printtoserver escaped hex values");
}
public Action hextest(int client, int args)
{
PrintToServer("\\x01 Test!");
PrintToServer("\x01");
PrintToServer("\\x02 Test!");
PrintToServer("\x02");
PrintToServer("\\x03 Test!");
PrintToServer("\x03");
PrintToServer("\\x04 Test!");
PrintToServer("\x04");
PrintToServer("\\x05 Test!");
PrintToServer("\x05");
PrintToServer("\\x06 Test!");
PrintToServer("\x06");
PrintToServer("\\x07 Test!");
PrintToServer("\x07");
PrintToServer("\\x08 Test!");
PrintToServer("\x08");
PrintToServer("\\x09 Test!");
PrintToServer("\x09");
PrintToServer("\\x10 Test!");
PrintToServer("\x10");
PrintToServer("\\x11 Test!");
PrintToServer("\x11");
PrintToServer("\\x12 Test!");
PrintToServer("\x12");
PrintToServer("\\x13 Test!");
PrintToServer("\x13");
PrintToServer("\\x14 Test!");
PrintToServer("\x14");
PrintToServer("\\x015 Test!");
PrintToServer("\x15");
return Plugin_Handled;
}