diff --git a/checkin_notes b/checkin_notes
index 19e26b6171..d3d5174017 100755
--- a/checkin_notes
+++ b/checkin_notes
@@ -6034,3 +6034,16 @@ Rom 8 June 2007
client/
configure.ac
version.h
+
+David 11 June 2007
+ - manager: fix bug in parsing of all-projects list
+ (caused Wizard list to be empty)
+ - manager: change (web) to WWW
+
+ client/
+ acct_mgr.C
+ cs_statefile.C
+ clientgui/
+ ProjectListCtrl.cpp
+ lib/
+ gui_rpc_client_ops.C
diff --git a/client/acct_mgr.C b/client/acct_mgr.C
index f3cf8f9a1b..ededbd10c1 100644
--- a/client/acct_mgr.C
+++ b/client/acct_mgr.C
@@ -64,7 +64,7 @@ int ACCT_MGR_OP::do_rpc(
global_prefs_xml = 0;
}
- // if null URL, defect from current AMS
+ // if null URL, detach from current AMS
//
if (!strlen(url) && strlen(gstate.acct_mgr_info.acct_mgr_url)) {
msg_printf(NULL, MSG_INFO, "Removing account manager info");
@@ -115,13 +115,13 @@ int ACCT_MGR_OP::do_rpc(
gstate.acct_mgr_info.previous_host_cpid
);
}
+
+ // If the AMS requested it, send GUI RPC port and password hash.
+ // This is for the "farm" account manager so it
+ // can know where to send GUI RPC requests to
+ // without having to configure each host
+ //
if (gstate.acct_mgr_info.send_gui_rpc_info) {
- // send GUI RPC port and password hash.
- // User must enable this by hand
- // this is for the "farm" account manager so it
- // can know where to send gui rpc requests to
- // without having to configure each host
- //
if (gstate.cmdline_gui_rpc_port) {
fprintf(f," %d\n", gstate.cmdline_gui_rpc_port);
} else {
@@ -659,12 +659,6 @@ int ACCT_MGR_INFO::init() {
bool ACCT_MGR_INFO::poll() {
if (gstate.acct_mgr_op.error_num == ERR_IN_PROGRESS) return false;
- // if we do not any any credentials we shouldn't attempt to contact
- // the account manager should should reject us anyway for a bad
- // login. This also avoids the bug where the content of
- // acct_mgr_url.xml is overwritten with incomplete information such
- // as the account manager name.
- //
if (!strlen(login_name) && !strlen(password_hash)) return false;
if (gstate.now > next_rpc_time) {
diff --git a/client/cs_statefile.C b/client/cs_statefile.C
index d5aecfb1e9..6ee3638f45 100644
--- a/client/cs_statefile.C
+++ b/client/cs_statefile.C
@@ -100,9 +100,11 @@ int CLIENT_STATE::parse_state_file() {
while (fgets(buf, 256, f)) {
if (match_tag(buf, "")) {
break;
- } else if (match_tag(buf, "")) {
+ }
+ if (match_tag(buf, "")) {
continue;
- } else if (match_tag(buf, "")) {
+ }
+ if (match_tag(buf, "")) {
PROJECT temp_project;
retval = temp_project.parse_state(mf);
if (retval) {
@@ -118,7 +120,9 @@ int CLIENT_STATE::parse_state_file() {
);
}
}
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
APP* app = new APP;
retval = app->parse(mf);
if (!project) {
@@ -150,7 +154,9 @@ int CLIENT_STATE::parse_state_file() {
continue;
}
apps.push_back(app);
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
FILE_INFO* fip = new FILE_INFO;
retval = fip->parse(mf, false);
if (!project) {
@@ -206,7 +212,9 @@ int CLIENT_STATE::parse_state_file() {
);
}
}
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
APP_VERSION* avp = new APP_VERSION;
retval = avp->parse(mf);
if (!project) {
@@ -244,7 +252,9 @@ int CLIENT_STATE::parse_state_file() {
continue;
}
app_versions.push_back(avp);
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
WORKUNIT* wup = new WORKUNIT;
retval = wup->parse(mf);
if (!project) {
@@ -270,7 +280,9 @@ int CLIENT_STATE::parse_state_file() {
continue;
}
workunits.push_back(wup);
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
RESULT* rp = new RESULT;
retval = rp->parse_state(mf);
if (!project) {
@@ -312,7 +324,9 @@ int CLIENT_STATE::parse_state_file() {
}
rp->wup->version_num = rp->version_num;
results.push_back(rp);
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
if (!project) {
msg_printf(NULL, MSG_INTERNAL_ERROR,
"Project files outside project in state file"
@@ -322,63 +336,97 @@ int CLIENT_STATE::parse_state_file() {
}
project->parse_project_files(mf, false);
project->link_project_files(false);
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
retval = host_info.parse(mf);
if (retval) {
msg_printf(NULL, MSG_INTERNAL_ERROR,
"Can't parse host info in state file"
);
}
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
retval = time_stats.parse(mf);
if (retval) {
msg_printf(NULL, MSG_INTERNAL_ERROR,
"Can't parse time stats in state file"
);
}
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
retval = net_stats.parse(mf);
if (retval) {
msg_printf(NULL, MSG_INTERNAL_ERROR,
"Can't parse network stats in state file"
);
}
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
retval = active_tasks.parse(mf);
if (retval) {
msg_printf(NULL, MSG_INTERNAL_ERROR,
"Can't parse active tasks in state file"
);
}
- } else if (parse_str(buf, "", statefile_platform_name)) {
continue;
- } else if (match_tag(buf, "")) {
+ }
+ if (parse_str(buf, "", statefile_platform_name)) {
continue;
- } else if (parse_int(buf, "", retval)) {
+ }
+ if (match_tag(buf, "")) {
+ continue;
+ }
+ if (parse_int(buf, "", retval)) {
run_mode.set(retval, 0);
continue;
- } else if (parse_int(buf, "", retval)) {
+ }
+ if (parse_int(buf, "", retval)) {
network_mode.set(retval, 0);
continue;
- } else if (parse_int(buf, "", old_major_version)) {
- } else if (parse_int(buf, "", old_minor_version)) {
- } else if (parse_int(buf, "", old_release)) {
- } else if (match_tag(buf, "")) {
+ }
+ if (parse_int(buf, "", old_major_version)) {
+ continue;
+ }
+ if (parse_int(buf, "", old_minor_version)) {
+ continue;
+ }
+ if (parse_int(buf, "", old_release)) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
run_cpu_benchmarks = true;
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
work_fetch_no_new_work = true;
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
retval = proxy_info.parse(mf);
if (retval) {
msg_printf(NULL, MSG_INTERNAL_ERROR,
"Can't parse proxy info in state file"
);
}
- } else if (parse_str(buf, "", main_host_venue, sizeof(main_host_venue))) {
- } else if (parse_double(buf, "", new_version_check_time)) {
- } else if (parse_double(buf, "", all_projects_list_check_time)) {
- } else if (parse_str(buf, "", newer_version)) {
- } else if (match_tag(buf, "")) {
+ continue;
+ }
+ if (parse_str(buf, "", main_host_venue, sizeof(main_host_venue))) {
+ continue;
+ }
+ if (parse_double(buf, "", new_version_check_time)) {
+ continue;
+ }
+ if (parse_double(buf, "", all_projects_list_check_time)) {
+ continue;
+ }
+ if (parse_str(buf, "", newer_version)) {
+ continue;
+ }
+ if (match_tag(buf, "")) {
if (!project) {
msg_printf(NULL, MSG_INTERNAL_ERROR,
"auto update outside project in state file"
@@ -389,14 +437,14 @@ int CLIENT_STATE::parse_state_file() {
if (!auto_update.parse(mf) && !auto_update.validate_and_link(project)) {
auto_update.present = true;
}
- } else {
- if (log_flags.unparsed_xml) {
- msg_printf(0, MSG_INFO,
- "[unparsed_xml] state_file: unrecognized: %s", buf
- );
- }
- skip_unrecognized(buf, mf);
+ continue;
}
+ if (log_flags.unparsed_xml) {
+ msg_printf(0, MSG_INFO,
+ "[unparsed_xml] state_file: unrecognized: %s", buf
+ );
+ }
+ skip_unrecognized(buf, mf);
}
fclose(f);
return 0;
diff --git a/clientgui/ProjectListCtrl.cpp b/clientgui/ProjectListCtrl.cpp
index 189d95a1c6..ceeb0171e5 100644
--- a/clientgui/ProjectListCtrl.cpp
+++ b/clientgui/ProjectListCtrl.cpp
@@ -299,7 +299,7 @@ bool CProjectListItemCtrl::SetTitle( wxString strTitle ) {
bool CProjectListItemCtrl::SetURL( wxString strURL ) {
if (m_pWebsiteCtrl) {
- m_pWebsiteCtrl->SetLabel(_("(web)"));
+ m_pWebsiteCtrl->SetLabel(_("WWW"));
m_pWebsiteCtrl->SetURL(strURL);
}
m_strURL = strURL;
diff --git a/lib/gui_rpc_client_ops.C b/lib/gui_rpc_client_ops.C
index 8f8b72c747..9bd2b65a82 100644
--- a/lib/gui_rpc_client_ops.C
+++ b/lib/gui_rpc_client_ops.C
@@ -1406,8 +1406,8 @@ int RPC_CLIENT::get_all_projects_list(ALL_PROJECTS_LIST& pl) {
if (retval) return retval;
XML_PARSER xp(&rpc.fin);
while (!xp.get(tag, sizeof(tag), is_tag)) {
- if (strstr(tag, "/projects")) break;
- else if (strstr(tag, "project")) {
+ if (!strcmp(tag, "/projects")) break;
+ else if (!strcmp(tag, "project")) {
project = new PROJECT_LIST_ENTRY();
retval = project->parse(xp);
if (!retval) {