diff --git a/README.rst b/README.rst index d22b4a0..3ff739a 100644 --- a/README.rst +++ b/README.rst @@ -185,7 +185,8 @@ log_append silent_connection If set to "1", the status window with the OpenVPN log output will - not be showed while connecting. + not be shown while connecting. Warnings such as interactive service + not started or multiple config files with same name are also suppressed. service_only If set to "1", OpenVPN GUI's normal "Connect" and "Disconnect" diff --git a/main.c b/main.c index b3bf2c7..b1eef79 100644 --- a/main.c +++ b/main.c @@ -189,7 +189,7 @@ int WINAPI _tWinMain (HINSTANCE hThisInstance, exit(1); } - if (!IsUserAdmin() && strtod(o.ovpn_version, NULL) > 2.3) + if (!IsUserAdmin() && strtod(o.ovpn_version, NULL) > 2.3 && !o.silent_connection) CheckIServiceStatus(TRUE); BuildFileList(); diff --git a/openvpn_config.c b/openvpn_config.c index cccc800..225bd57 100644 --- a/openvpn_config.c +++ b/openvpn_config.c @@ -221,6 +221,9 @@ BuildFileList() { static bool issue_warnings = true; + if (o.silent_connection) + issue_warnings = false; + /* * If no connections are active reset num_configs and rescan * to make a new list. Else we keep all current configs and diff --git a/res/openvpn-gui-res-en.rc b/res/openvpn-gui-res-en.rc index cc35edb..e2ee8ac 100644 --- a/res/openvpn-gui-res-en.rc +++ b/res/openvpn-gui-res-en.rc @@ -355,7 +355,7 @@ BEGIN "--allow_proxy\t\t: 1=Show Proxy Settings menu.\n" \ "--show_balloon\t\t: 0=Never, 1=At initial connect, 2=At every re-connect.\n" \ "--service_only\t\t: 1=Enable Service Only mode.\n" \ - "--silent_connection\t\t: 1=Do not show the status dialog while connecting.\n" \ + "--silent_connection\t\t: 1=Do not show the status dialog while connecting or non-critical warnings at startup.\n" \ "--show_script_window\t: 0=Hide Script execution window, 1=Show it.\n" \ "--passphrase_attempts\t: Number of passphrase attempts to allow.\n" \ "--connectscript_timeout\t: Time to wait for connect script to finish.\n" \