- back end programs: optional BOINC_CONFIG_XML environment variable

specifies path of config file (default: ../config.xml)

svn path=/trunk/boinc/; revision=16011
This commit is contained in:
David Anderson 2008-09-17 21:14:47 +00:00
parent 9d91ac8428
commit 750fe8795a
2 changed files with 13 additions and 1 deletions

View File

@ -7494,3 +7494,10 @@ David 17 Sept 2008
language_select.php
sched/
hr_info.C
David 17 Sept 2008
- back end programs: optional BOINC_CONFIG_XML environment variable
specifies path of config file (default: ../config.xml)
sched/
sched_config.C

View File

@ -219,7 +219,12 @@ int SCHED_CONFIG::parse_file(const char* dir) {
char path[256];
int retval;
sprintf(path, "%s/%s", dir, CONFIG_FILE);
char* p = getenv("BOINC_CONFIG_XML");
if (p) [
strcpy(path, p)
} else {
sprintf(path, "%s/%s", dir, CONFIG_FILE);
}
#ifndef _USING_FCGI_
FILE* f = fopen(path, "r");
#else