mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-01-25 19:34:13 +00:00
Destination: cut name for thread name
Signed-off-by: r4sas <r4sas@i2pmail.org>
This commit is contained in:
parent
ce96f93c80
commit
ce0461bf86
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2013-2023, The PurpleI2P Project
|
* Copyright (c) 2013-2024, The PurpleI2P Project
|
||||||
*
|
*
|
||||||
* This file is part of Purple i2pd project and licensed under BSD3
|
* This file is part of Purple i2pd project and licensed under BSD3
|
||||||
*
|
*
|
||||||
@ -171,6 +171,14 @@ namespace util
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void RunnableService::SetName (std::string_view name)
|
||||||
|
{
|
||||||
|
if (name.length() < 16)
|
||||||
|
m_Name = name;
|
||||||
|
else
|
||||||
|
m_Name = name.substr(0,15);
|
||||||
|
}
|
||||||
|
|
||||||
void SetThreadName (const char *name) {
|
void SetThreadName (const char *name) {
|
||||||
#if defined(__APPLE__)
|
#if defined(__APPLE__)
|
||||||
# if (!defined(MAC_OS_X_VERSION_10_6) || \
|
# if (!defined(MAC_OS_X_VERSION_10_6) || \
|
||||||
|
@ -183,7 +183,7 @@ namespace util
|
|||||||
void StartIOService ();
|
void StartIOService ();
|
||||||
void StopIOService ();
|
void StopIOService ();
|
||||||
|
|
||||||
void SetName (std::string_view name) { m_Name = name; };
|
void SetName (std::string_view name);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user