vncserver: refactor

This commit is contained in:
Dmitry Maksyoma 2021-07-30 23:40:51 +12:00
parent b330856d67
commit fc732f3603

View File

@ -405,7 +405,7 @@ if (! $skipxstartup) {
warn "Log file is $desktopLog\n\n"; warn "Log file is $desktopLog\n\n";
if (! $skipxstartup) { if (! $skipxstartup) {
&DetectDisplay(); &DetectAndExportDisplay();
$ENV{VNCDESKTOP}= $desktopName; $ENV{VNCDESKTOP}= $desktopName;
&RunXstartup(); &RunXstartup();
@ -890,7 +890,7 @@ sub CreateXstartup
chmod 0755, "$xstartupFile"; chmod 0755, "$xstartupFile";
} }
sub DetectDisplay { sub DetectAndExportDisplay {
# If the unix domain socket exists then use that (DISPLAY=:n) otherwise use # If the unix domain socket exists then use that (DISPLAY=:n) otherwise use
# TCP (DISPLAY=host:n) # TCP (DISPLAY=host:n)