diff --git a/hw/xquartz/darwinEvents.c b/hw/xquartz/darwinEvents.c index 89e73c47a..6ec8c0f22 100644 --- a/hw/xquartz/darwinEvents.c +++ b/hw/xquartz/darwinEvents.c @@ -266,16 +266,9 @@ static void DarwinEventHandler(int screenNum, xEventPtr xe, DeviceIntPtr dev, in } } -#ifdef XQUARTZ_EXPORTS_LAUNCHD_FD -int xquartz_launchd_fd = -1; -#endif - void DarwinListenOnOpenFD(int fd) { ErrorF("DarwinListenOnOpenFD: %d\n", fd); -#ifdef XQUARTZ_EXPORTS_LAUNCHD_FD - xquartz_launchd_fd = fd; -#else pthread_mutex_lock(&fd_add_lock); if(fd_add_count < FD_ADD_MAX) fd_add[fd_add_count++] = fd; @@ -284,7 +277,6 @@ void DarwinListenOnOpenFD(int fd) { pthread_cond_broadcast(&fd_add_ready_cond); pthread_mutex_unlock(&fd_add_lock); -#endif } static void DarwinProcessFDAdditionQueue_thread(void *args) { diff --git a/hw/xquartz/mach-startup/bundle-main.c b/hw/xquartz/mach-startup/bundle-main.c index 9f03647d2..a49013e0d 100644 --- a/hw/xquartz/mach-startup/bundle-main.c +++ b/hw/xquartz/mach-startup/bundle-main.c @@ -213,7 +213,6 @@ static void socket_handoff_thread(void *arg) { unlink(handoff_data->filename); free(handoff_data); -#ifndef XQUARTZ_EXPORTS_LAUNCHD_FD /* TODO: Clean up this race better... giving xinitrc time to run... need to wait for 1.5 branch: * * From ajax: @@ -226,7 +225,6 @@ static void socket_handoff_thread(void *arg) { unsigned remain = 3000000; fprintf(stderr, "X11.app: Received new $DISPLAY fd: %d ... sleeping to allow xinitrc to catchup.\n", launchd_fd); while((remain = usleep(remain)) > 0); -#endif fprintf(stderr, "X11.app Handing off fd to server thread via DarwinListenOnOpenFD(%d)\n", launchd_fd); DarwinListenOnOpenFD(launchd_fd); @@ -398,13 +396,6 @@ int startup_trigger(int argc, char **argv, char **envp) { /* Could open the display, start the launcher */ XCloseDisplay(display); -#ifdef XQUARTZ_EXPORTS_LAUNCHD_FD - fprintf(stderr, "X11.app: Received new DISPLAY fd: %d ... sleeping to allow xinitrc to catchup.\n", launchd_fd); - - /* TODO: Clean up this race better... givint xinitrc time to run. */ - sleep(2); -#endif - return execute(command_from_prefs("app_to_run", DEFAULT_CLIENT)); } }