Mac: Redirect stderr to gfx_stderr.txt so we have a way to get error messages from system for graphics app

svn path=/trunk/boinc_samples/; revision=13492
This commit is contained in:
Charlie Fenton 2007-08-29 14:17:00 +00:00
parent 6ddfe45523
commit 1a98074b66
2 changed files with 9 additions and 1 deletions

View File

@ -423,7 +423,11 @@ David 17 Aug 2007
Charlie 29 Aug 2007
- Mac: new XCode project for version 6 example_app.
- Mac: Redirect stderr to gfx_stderr.txt so we have a way to get
error messages from system for graphics app.
example_app/
uc2_graphics.C
mac_build/
UpperCase2.xcodeproj/
project.pbxproj

View File

@ -242,6 +242,10 @@ static void parse_project_prefs(char* buf) {
}
int main(int argc, char** argv) {
#ifdef __APPLE__
// Provide a way to get error messages from system
freopen("gfx_stderr.txt", "w", stderr);
#endif
shmem = (UC_SHMEM*)boinc_graphics_get_shmem("uppercase");
boinc_parse_init_data_file();
boinc_get_init_data(uc_aid);