mirror of
https://github.com/moonlight-stream/moonlight-embedded.git
synced 2025-08-17 17:06:10 +00:00
Load host specific settings from configuration file
This commit is contained in:
parent
7a200fea64
commit
d3c3ba92c7
@ -266,7 +266,7 @@ void config_parse(int argc, char* argv[], PCONFIGURATION config) {
|
||||
char* config_file = get_path("moonlight.conf", "/etc");
|
||||
if (config_file)
|
||||
config_file_parse(config_file, config);
|
||||
|
||||
|
||||
if (argc == 2 && access(argv[1], F_OK) == 0) {
|
||||
config->action = "stream";
|
||||
config_file_parse(argv[1], config);
|
||||
|
@ -177,6 +177,10 @@ int main(int argc, char* argv[]) {
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
|
||||
char host_config_file[128];
|
||||
sprintf(host_config_file, "hosts/%s.conf", config.address);
|
||||
config_file_parse(host_config_file, &config);
|
||||
|
||||
PSERVER_DATA server;
|
||||
if (gs_init(server, config.address, config.key_dir) != GS_OK) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user