- scheduler: if host.n_bwdown is zero, skip the bandwidth check;

the host hasn't been measured yet.

svn path=/trunk/boinc/; revision=15409
This commit is contained in:
David Anderson 2008-06-17 16:09:27 +00:00
parent ccc92976e9
commit d737c428ff
6 changed files with 38 additions and 21 deletions

View File

@ -4887,3 +4887,10 @@ David 16 June 2008
client/
client_state.C
David 16 June 2008
- scheduler: if host.n_bwdown is zero, skip the bandwidth check;
the host hasn't been measured yet.
sched/
sched_send.C

View File

@ -190,29 +190,27 @@ int get_timezone() {
// Returns true if the host is currently running off battery power
// If you can't figure out, return false
//
// TODO: port this to other platforms (Windows, others?)
//
bool HOST_INFO::host_is_running_on_batteries() {
#if defined(__APPLE__)
CFDictionaryRef pSource = NULL;
CFStringRef psState;
int i;
bool retval = false;
CFDictionaryRef pSource = NULL;
CFStringRef psState;
int i;
bool retval = false;
CFTypeRef blob = IOPSCopyPowerSourcesInfo();
CFArrayRef list = IOPSCopyPowerSourcesList(blob);
CFTypeRef blob = IOPSCopyPowerSourcesInfo();
CFArrayRef list = IOPSCopyPowerSourcesList(blob);
for(i = 0; i < CFArrayGetCount(list); i++) {
pSource = IOPSGetPowerSourceDescription(blob, CFArrayGetValueAtIndex(list, i));
if(!pSource) break;
psState = (CFStringRef)CFDictionaryGetValue(pSource, CFSTR(kIOPSPowerSourceStateKey));
if(!CFStringCompare(psState,CFSTR(kIOPSBatteryPowerValue),0))
retval = true;
}
for (i=0; i<CFArrayGetCount(list); i++) {
pSource = IOPSGetPowerSourceDescription(blob, CFArrayGetValueAtIndex(list, i));
if(!pSource) break;
psState = (CFStringRef)CFDictionaryGetValue(pSource, CFSTR(kIOPSPowerSourceStateKey));
if(!CFStringCompare(psState,CFSTR(kIOPSBatteryPowerValue),0))
retval = true;
}
CFRelease(blob);
CFRelease(list);
return(retval);
CFRelease(blob);
CFRelease(list);
return retval;
#elif LINUX_LIKE_SYSTEM
bool retval = false;

View File

@ -90,7 +90,7 @@ array('SETI_at_BOINCWatch_1.10.15.exe',
'SETI@BOINCWatch',
'1.10.15',
'A SETI@Home/BOINC client watcher! User statistics powered by BOINCStats',
'http://setiwatch.hit.bg/',
'http://www.setiboincwatch.org/',
'',
'Logging finished results which you can review in details later, builtin; starmap whish shows the position of the current WU and all the logged results; user, team and country statistics powered by BOINCStats and many more features included...',
1115657242
@ -99,7 +99,7 @@ array('SETIatBOINCWatch(.NET2.0).exe',
'SETI@BOINCWatch(.NET 2.0)',
'3.0.24 BETA',
'A SETI@Home/BOINC client watcher! User statistics powered by BOINCStats. But now built with the .NET environment.',
'http://setiwatch.hit.bg/',
'http://www.setiboincwatch.org/',
'2000/XP family/2003 Server family',
'Logging finished results which you can review in details later, builtin; starmap whish shows the position of the current WU and all the logged results; user, team and country statistics powered by BOINCStats and many more features included...',
1145198333
@ -108,7 +108,7 @@ array('SETIatBOINCWatch(.NET).exe',
'SETI@BOINCWatch(.NET)',
'2.0.24 BETA',
'A SETI@Home/BOINC client watcher! User statistics powered by BOINCStats. But now built with the .NET environment.',
'http://setiwatch.hit.bg/',
'http://www.setiboincwatch.org/',
'2000/XP family/2003 Server family',
'Logging finished results which you can review in details later, builtin; starmap whish shows the position of the current WU and all the logged results; user, team and country statistics powered by BOINCStats and many more features included...',
1145198264

View File

@ -1,6 +1,10 @@
<?
$project_news = array(
array("June 16, 2008",
"<a href=logo/logo_3d>3-D versions of the BOINC logo</a>
are now available; thanks to John from Ireland for creating these."
),
array("June 2, 2008",
"BOINCstats and BAM! are now available in
<a href=http://br.boincstats.com/>Brazilian Portuguese</a> and

View File

@ -40,7 +40,9 @@ The colors are based on U.C. Berkeley's blue-and-gold colors.
<li> <a href=logo/boinc_logo_ai.svg>Scalable Vector Graphics (.svg)</a>
<li> <a href=logo/boinc_logo.png>1280x535, transparent background (.png)</a>
<li> <a href=logo/boinc_logo.wmf>Windows meta-file (.wmf)</a>
<li> <a href=logo/logo_3d>3D versions (various sizes)</a>
</ul>
<
Icon:
<ul>
<li> Bitmaps (.bmp):

View File

@ -518,6 +518,12 @@ static inline int check_bandwidth(
WORKUNIT& wu, SCHEDULER_REQUEST& , SCHEDULER_REPLY& reply
) {
if (wu.rsc_bandwidth_bound == 0) return 0;
// if n_bwdown is zero, the host has never downloaded anything,
// so skip this check
//
if (host.n_bwdown == 0) return 0;
double diff = wu.rsc_bandwidth_bound - reply.host.n_bwdown;
if (diff > 0) {
char message[256];