os/utils.c: Create lock file on explicit display, even on '-displayfd'
An explicit display can be passed on the command-line along with -displayfd
, in which case the display selection logic of -displayfd
is bypassed (the presence of -displayfd
still causes the output of the selected display to the argument fd after sockets have been established; the combination of these parameters is meaningful).
But, in this case, no lock file is used and the server goes through the regular socket creation process, which may or may not give an error (if it doesn't, e.g., when launched as root, an existing socket may be crushed, see also issue xorg/lib/libxtrans#4). This is inconsistent with the case when -displayfd
is not present, and in case of failure causes a poorer error to be reported.