mirror of https://github.com/BOINC/boinc.git
Merge pull request #2138 from bema-aei/validate_suspicious_results
validator: raise the quorum for 'suspicious' results to ensure validation
This commit is contained in:
commit
16e7c516d6
|
@ -116,6 +116,16 @@ int check_set(
|
|||
good_results += suspicious_results;
|
||||
}
|
||||
|
||||
// if there are "suspicious" results and min_quorum < g_app->target_nresults
|
||||
// (i.e. adaptive replication), raise min_quorum to g_app->target_nresults
|
||||
// the abs() is there for Einstein@Home-specific use of app->target_nresults,
|
||||
// please leave it in there.
|
||||
//
|
||||
if (suspicious_results && wu.min_quorum < abs(g_app->target_nresults)) {
|
||||
log_messages.printf(MSG_NORMAL, "suspicious result - raising quorum\n");
|
||||
wu.min_quorum = abs(g_app->target_nresults);
|
||||
}
|
||||
|
||||
if (good_results < wu.min_quorum) goto cleanup;
|
||||
|
||||
// Compare results
|
||||
|
|
|
@ -90,6 +90,7 @@ typedef enum {
|
|||
|
||||
char app_name[256];
|
||||
DB_APP app;
|
||||
DB_APP* g_app = &app;
|
||||
int wu_id_modulus=0;
|
||||
int wu_id_remainder=0;
|
||||
int wu_id_min=0;
|
||||
|
|
|
@ -24,3 +24,6 @@ extern WORKUNIT* g_wup;
|
|||
// A pointer to the WU currently being processed;
|
||||
// you can access this in your init_result() etc. functions
|
||||
// (which are passed RESULT but not WORKUNIT)
|
||||
|
||||
extern DB_APP* g_app;
|
||||
// a pointer to the app (similar to above)
|
||||
|
|
Loading…
Reference in New Issue