I never encountered this until running on a multi-core system.
My application calls Xinitscr(), and then in my main thread calls init_pair() which never returns. The child process spawned by XCursesInitscr() is at 100% CPU. Attaching to the child process shows it stuck in _XtWaitForSomething() inside XtAppMainLoop(). The parent process is blocked at the read() in XC_read_socket().
Inserting a sleep(2) at the beginning of _setup_curses() in pdcx11.c alleviates this issue for this machine. Also, manually stepping through the parent process _setup_curses() in gdb makes this non-reproducible.
This looks very similar to https://bugs.freedesktop.org/show_bug.cgi?id=809 .