*** empty log message ***

svn path=/trunk/boinc/; revision=4927
This commit is contained in:
David Anderson 2004-12-23 06:10:53 +00:00
parent 7f4b9e4b8f
commit 452c6831cc
2 changed files with 20 additions and 10 deletions

View File

@ -192,29 +192,32 @@ void restart() {
void xwin_graphics_event_loop() {
char* args[] = {"foobar", 0};
int one=1;
static bool first=true;
static bool glut_inited = false;
graphics_thread = pthread_self();
atexit(restart);
int restarted = setjmp(jbuf);
#ifdef __APPLE_CC__
first = true;
#endif
if (first) {
glutInit(&one, args);
first = false;
}
if (restarted) {
if (!glut_inited) {
// here glutInit() must have failed and called exit().
// returning will cause the graphics thread to exit.
return;
}
//fprintf(stderr, "graphics thread restarted\n"); fflush(stderr);
#ifdef __APPLE_CC__
glutInit(&one, args);
#endif
set_mode(MODE_HIDE_GRAPHICS);
} else {
glutInit(&one, args);
glut_inited = true;
if (boinc_is_standalone()) {
set_mode(MODE_WINDOW);
} else {
wait_for_initial_message();
timer_handler(0);
atexit(restart);
}
}
glutTimerFunc(TIMER_INTERVAL_MSEC, timer_handler, 0);

View File

@ -21757,3 +21757,10 @@ Rom 22 Dec 2004
Rom 22 Dec 2004 (boinc)
- Tag for 4.57 release, all platforms
boinc_core_release_4_57
David 22 Dec 2004
- shuffle logic in xwin_graphics_event_loop() to deal with
situation where glutInit() calls exit()
api/
x_opengl.C