Commit 80b0d63f authored by Titouan Soulard's avatar Titouan Soulard

trx-bridge: set high process priority

parent 123e260d
...@@ -190,6 +190,13 @@ int main(int argc, char *argv[]) { ...@@ -190,6 +190,13 @@ int main(int argc, char *argv[]) {
return -1; return -1;
} }
// Before starting anything, the process should be made as high
// priority as possible
if(nice(-20) != -20) {
fprintf(stderr, "Setting priority failed, run this program as root\n");
return -1;
}
printf("trx-bridge: reading configuration file %s\n", bridge_config_path); printf("trx-bridge: reading configuration file %s\n", bridge_config_path);
common_hashtable_initialize(&config, 255); common_hashtable_initialize(&config, 255);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment