mirror of https://github.com/BOINC/boinc.git
Mac SS: look for Branding file in BOINC Data folder before the one in Manager (mainly for convenience debugging on build system)
svn path=/branches/boinc_core_release_6_8/; revision=20479
This commit is contained in:
parent
4fe9e99e67
commit
a418d62918
|
@ -6582,6 +6582,14 @@ Charlie 2 Feb 2010
|
|||
res/
|
||||
gridrepublic_ss_logo.jpg
|
||||
|
||||
Charlie 2 Feb 2010
|
||||
- Mac SS: look for Branding file in BOINC Data folder before the one in Manager
|
||||
to avoid confusion if newer copies of BOINC Manager exist elsewhere on system.
|
||||
(This is primarily for convenience in debugging on build system)
|
||||
|
||||
clientscr/
|
||||
mac_saver_module.cpp
|
||||
|
||||
Charlie 4 Feb 2010
|
||||
- Mac Installer: when adding non-admin users to group boinc_master, also add
|
||||
them to group boinc_project; this fixes permissions error -1200 for non-
|
||||
|
|
|
@ -629,20 +629,22 @@ int CScreensaver::GetBrandID()
|
|||
|
||||
iBrandId = 0; // Default value
|
||||
|
||||
err = GetpathToBOINCManagerApp(buf, sizeof(buf));
|
||||
if (err) {
|
||||
// If we couldn't find our application bundle, look in BOINC Data Directory
|
||||
// (the installer put a copy there for us)
|
||||
strcpy(buf, "/Library/Application Support/BOINC Data/Branding");
|
||||
} else
|
||||
strcat(buf, "/Contents/Resources/Branding");
|
||||
|
||||
FILE *f = fopen(buf, "r");
|
||||
// The installer put a copy of Branding file in the BOINC Data Directory
|
||||
FILE *f = fopen("/Library/Application Support/BOINC Data/Branding", "r");
|
||||
if (f == NULL) {
|
||||
// If we couldn't find our Branding file in the BOINC Data Directory,
|
||||
// look in our application bundle
|
||||
err = GetpathToBOINCManagerApp(buf, sizeof(buf));
|
||||
if (err == noErr) {
|
||||
strcat(buf, "/Contents/Resources/Branding");
|
||||
f = fopen(buf, "r");
|
||||
}
|
||||
}
|
||||
if (f) {
|
||||
fscanf(f, "BrandId=%ld\n", &iBrandId);
|
||||
fclose(f);
|
||||
}
|
||||
|
||||
|
||||
return iBrandId;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue