From 106bad321924ad4c189cd55015c9d431289de1bb Mon Sep 17 00:00:00 2001 From: Eric Heien Date: Wed, 18 Dec 2002 20:18:06 +0000 Subject: [PATCH] save some global prefs locally svn path=/trunk/boinc/; revision=761 --- client/client_state.C | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/client/client_state.C b/client/client_state.C index a826a027ea..c28c6dc3ff 100644 --- a/client/client_state.C +++ b/client/client_state.C @@ -390,6 +390,9 @@ int CLIENT_STATE::parse_state_file() { int retval=0; int failnum; + global_prefs.confirm_before_connecting = false; + global_prefs.hangup_if_dialed = false; + if (!f) { if (log_flags.state_debug) { printf("No state file; will create one\n"); @@ -494,7 +497,11 @@ int CLIENT_STATE::parse_state_file() { // TODO: handle old client state file if different version } else if (match_tag(buf, "")) { // TODO: handle old client state file if different version - } else if (match_tag(buf, "")) { + } else if (match_tag(buf, "")) { + global_prefs.confirm_before_connecting = true; + } else if (match_tag(buf, "")) { + global_prefs.hangup_if_dialed = true; + } else if (match_tag(buf, "")) { use_proxy = true; } else if (parse_str(buf, "", proxy_server_name, sizeof(proxy_server_name))) { } else if (parse_int(buf, "", proxy_server_port)) { @@ -559,10 +566,14 @@ int CLIENT_STATE::write_state_file() { ); // save proxy info fprintf(f, + "%s" + "%s" "%s" "%s\n" "%d\n", - use_proxy?"\n":"", + use_proxy?"\n":"", + global_prefs.confirm_before_connecting?"\n":"", + global_prefs.hangup_if_dialed?"\n":"", proxy_server_name, proxy_server_port );