Skip to content

Commit

Permalink
Telemetry service directory override.
Browse files Browse the repository at this point in the history
In addition to opt-in for telemetry (see MisterTea#553) this uses the log
directory override from MisterTea#556 to place the sentry/telemetry logs.
  • Loading branch information
jshort committed May 2, 2024
1 parent 2f8dfdd commit 5e3b438
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/terminal/TerminalServerMain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ int main(int argc, char **argv) {

int port = 0;
string bindIp = "";
bool telemetry = false;
bool enableTelemetry = false;
string logDirectory = GetTempDirectory();
if (result.count("cfgfile")) {
// Load the config file
Expand All @@ -101,7 +101,7 @@ int main(int argc, char **argv) {
}
}

telemetry = ini.GetBoolValue("Debug", "telemetry", false);
enableTelemetry = ini.GetBoolValue("Debug", "telemetry", false);
// read verbose level (prioritize command line option over cfgfile)
const char *vlevel = ini.GetValue("Debug", "verbose", NULL);
if (result.count("verbose")) {
Expand Down Expand Up @@ -155,7 +155,7 @@ int main(int argc, char **argv) {
}

if (result.count("telemetry")) {
telemetry = result["telemetry"].as<bool>();
enableTelemetry = result["telemetry"].as<bool>();
}

if (result.count("logdir")) {
Expand All @@ -181,7 +181,7 @@ int main(int argc, char **argv) {
el::Helpers::installPreRollOutCallback(LogHandler::rolloutHandler);

TelemetryService::create(
telemetry, GetTempDirectory() + "/.sentry-native-etserver", "Server");
enableTelemetry, logDirectory + "/.sentry-native-etserver", "Server");

serverFifo.createDirectoriesIfRequired();

Expand Down

0 comments on commit 5e3b438

Please sign in to comment.