vncserver: refactor

This commit is contained in:
Dmitry Maksyoma 2021-08-13 01:18:09 +12:00
parent 9a6ea64e0f
commit acb9793841

View File

@ -32,8 +32,6 @@ use Time::HiRes qw (sleep);
&SetGlobalVariables();
&ParseAndProcessCliOptions();
$vncPort = 5900 + $displayNumber;
$desktopName = $opt{'-name'} || "$host:$displayNumber ($ENV{USER})";
$desktopLog = "$vncUserDir/$host:$displayNumber.log";
$pidFile = "$vncUserDir/$host:$displayNumber.pid";
@ -1043,6 +1041,9 @@ sub PrepareDefaultsForPassingToXvnc {
%default_opts;
%config;
$vncPort = 5900 + $displayNumber;
$desktopName = $opt{'-name'} || "$host:$displayNumber ($ENV{USER})";
&SetReasonabeDefaults();
&LoadSystemThenUserThenMandatoryConfigs();
}