forked from joejulian/gio
d31a129bf9
First, pick a random display number between 1 and 100,000. The pool is large enough that we don't need to think about collisions for now. Second, wait for the X server to expose its socket for up to 1s, instead of doing a single static sleep of 200ms. The average time we actually need to sleep on my laptop is around 5ms, so this gives a noticeable speed-up. Signed-off-by: Daniel Martí <mvdan@mvdan.cc>