Commit db0966bb authored by Seblu's avatar Seblu

Add server and port to getopt env

parent fad11139
......@@ -100,6 +100,14 @@ Options &Options::load(int argc, char *argv[]) {
Options &Options::loadenv() {
const char *senv;
// Get slc server ip
if ((senv = getenv("SLC_SERVER")) != 0 && *senv != 0)
server = senv;
// Get slc port
if ((senv = getenv("SLC_PORT")) != 0 && *senv != 0)
port = atoi(senv);
// Get history path
if ((senv = getenv("SLC_HISTORY_FILE")) != 0 && *senv != 0)
history_file = senv;
......
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