+ To use this, you must be logged in as a user + with permission to submit jobs. +
"; show_button("submit_example.php?action=create_form", "Create new batch"); @@ -71,7 +74,7 @@ function handle_main() { if ($batch->state != BATCH_STATE_IN_PROGRESS) continue; if ($first) { $first = false; - echo "
Return to job control page\n"; page_tail(); } diff --git a/sched/credit.cpp b/sched/credit.cpp index 926c0b2aa5..23e754a9cb 100644 --- a/sched/credit.cpp +++ b/sched/credit.cpp @@ -406,7 +406,9 @@ int get_pfc( // old clients report CPU time but not elapsed time. // Use HOST_APP_VERSION.et to track statistics of CPU time. // - if (!r.elapsed_time) { + if (r.elapsed_time < 1e-6) { + // in case buggy client reports elapsed time like 1e-304 + if (config.debug_credit) { log_messages.printf(MSG_NORMAL, "[credit] [RESULT#%d] old client (elapsed time not reported)\n", diff --git a/sched/sched_types.cpp b/sched/sched_types.cpp index 851592d879..11a971a5c1 100644 --- a/sched/sched_types.cpp +++ b/sched/sched_types.cpp @@ -61,7 +61,7 @@ int CLIENT_APP_VERSION::parse(FILE* f) { char buf[256]; double x; - memset(this, 0, sizeof(CLIENT_APP_VERSION)); + memset(this, 0, sizeof(*this)); host_usage.avg_ncpus = 1; while (fgets(buf, sizeof(buf), f)) { if (match_tag(buf, "")) { @@ -110,7 +110,7 @@ int CLIENT_APP_VERSION::parse(FILE* f) { int FILE_INFO::parse(FILE* f) { char buf[256]; - memset(this, 0, sizeof(FILE_INFO)); + memset(this, 0, sizeof(*this)); while (fgets(buf, sizeof(buf), f)) { if (match_tag(buf, "")) { if (!strlen(name)) return ERR_XML_PARSE; @@ -1099,7 +1099,7 @@ int SCHED_DB_RESULT::parse_from_client(FILE* fin) { // should be non-zero if exit_status is not found exit_status = ERR_NO_EXIT_STATUS; - memset(this, 0, sizeof(RESULT)); + memset(this, 0, sizeof(*this)); while (fgets(buf, sizeof(buf), fin)) { if (match_tag(buf, "")) { return 0;