Merge branch 'master' into dcdc_rework
Conflicts: Xext/xevie.c dix/dispatch.c
This commit is contained in:
16
dix/main.c
16
dix/main.c
@@ -93,6 +93,7 @@ Equipment Corporation.
|
||||
#include "colormap.h"
|
||||
#include "colormapst.h"
|
||||
#include "cursorstr.h"
|
||||
#include "selection.h"
|
||||
#include <X11/fonts/font.h>
|
||||
#include "opaque.h"
|
||||
#include "servermd.h"
|
||||
@@ -112,6 +113,9 @@ Equipment Corporation.
|
||||
#include "dispatch.h" /* InitProcVectors() */
|
||||
#endif
|
||||
|
||||
#include <pthread.h>
|
||||
pthread_key_t threadname_key=0;
|
||||
|
||||
#ifdef DPMSExtension
|
||||
#define DPMS_SERVER
|
||||
#include <X11/extensions/dpms.h>
|
||||
@@ -247,6 +251,17 @@ main(int argc, char *argv[], char *envp[])
|
||||
char *xauthfile;
|
||||
HWEventQueueType alwaysCheckForInput[2];
|
||||
|
||||
if(threadname_key == 0) ErrorF("pthread_key_create returned %d\n", pthread_key_create(&threadname_key, NULL));
|
||||
ErrorF("threadname_key = %d\n", threadname_key);
|
||||
if(pthread_getspecific(threadname_key) == NULL) {
|
||||
char *nameptr = malloc(32);
|
||||
sprintf(nameptr, "main thread %d", random());
|
||||
// strcpy(nameptr, "main thread");
|
||||
ErrorF("calling: pthread_setspecific(%d, %s)=%d\n", threadname_key, nameptr, pthread_setspecific(threadname_key, nameptr));
|
||||
if (pthread_getspecific(threadname_key) != NULL) ErrorF("current thread: %s\n", (char *)pthread_getspecific(threadname_key));
|
||||
} else {
|
||||
if (pthread_getspecific(threadname_key) != NULL) ErrorF("thread was already: %s\n", (char *)pthread_getspecific(threadname_key));
|
||||
}
|
||||
display = "0";
|
||||
|
||||
InitGlobals();
|
||||
@@ -346,6 +361,7 @@ main(int argc, char *argv[], char *envp[])
|
||||
|
||||
InitAtoms();
|
||||
InitEvents();
|
||||
InitSelections();
|
||||
InitGlyphCaching();
|
||||
if (!dixResetPrivates())
|
||||
FatalError("couldn't init private data storage");
|
||||
|
||||
Reference in New Issue
Block a user