args: Support -nopid

This commit is contained in:
Hodlinator 2024-11-14 22:14:24 +01:00
parent 12f8d848fd
commit bffd92f00f
No known key found for this signature in database

View file

@ -175,6 +175,8 @@ static fs::path GetPidFile(const ArgsManager& args)
[[nodiscard]] static bool CreatePidFile(const ArgsManager& args)
{
if (args.IsArgNegated("-pid")) return true;
std::ofstream file{GetPidFile(args)};
if (file) {
#ifdef WIN32