Auto hotspot implementation
This commit is contained in:
@@ -215,6 +215,11 @@ void LogTrace(const std::string&path,const char*method,const std::string&message
|
||||
}
|
||||
}
|
||||
|
||||
void SetDBusLogger(std::unique_ptr<IDBusLogger> && logger)
|
||||
{
|
||||
loggers.clear();
|
||||
loggers.push_back(std::move(logger));
|
||||
}
|
||||
|
||||
void SetDBusConsoleLogger()
|
||||
{
|
||||
|
||||
@@ -42,6 +42,7 @@ void SetDBusConsoleLogger();
|
||||
void AddDBusConsoleLogger();
|
||||
void SetDBusSystemdLogger();
|
||||
void SetDBusFileLogger(const std::filesystem::path &path);
|
||||
void SetDBusLogger(std::unique_ptr<IDBusLogger>&&logger);
|
||||
|
||||
extern void LogError(const std::string&path,const char*method,const std::string&message);
|
||||
extern void LogInfo(const std::string&path,const char*method,const std::string&message);
|
||||
|
||||
@@ -193,7 +193,7 @@ void P2pSettings::Load()
|
||||
|
||||
}
|
||||
|
||||
static void openWithPerms(
|
||||
static void openWithRestrictedPerms(
|
||||
pipedal::ofstream_synced &f,
|
||||
const std::filesystem::path &path,
|
||||
std::filesystem::perms perms =
|
||||
@@ -229,7 +229,7 @@ void P2pSettings::Save()
|
||||
auto filename = config_filename();
|
||||
try {
|
||||
pipedal::ofstream_synced f;
|
||||
openWithPerms(f,filename);
|
||||
openWithRestrictedPerms(f,filename);
|
||||
|
||||
if (!f.is_open())
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user