mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Prevent invalid chars in logfile path
A proper error message is shown and bot is unloaded. Fix #153
This commit is contained in:
parent
66d57b0ce6
commit
c6c0c0e3a7
1 changed files with 5 additions and 0 deletions
|
|
@ -53,6 +53,11 @@ namespace MinecraftClient.ChatBots
|
|||
saveChat = false;
|
||||
break;
|
||||
}
|
||||
if (String.IsNullOrEmpty(file) || file.IndexOfAny(Path.GetInvalidPathChars()) >= 0)
|
||||
{
|
||||
LogToConsole("Path '" + file + "' contains invalid characters.");
|
||||
UnloadBot();
|
||||
}
|
||||
}
|
||||
|
||||
public static MessageFilter str2filter(string filtername)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue