Don't ask if user wants to create znc.pem or not

Sure they want!
This commit is contained in:
Alexey Sokolov
2014-01-27 00:07:17 +00:00
parent 60b2f559dc
commit 05ca849339
+9 -13
View File
@@ -600,19 +600,7 @@ bool CZNC::WriteNewConfig(const CString& sConfigFile) {
#ifdef HAVE_LIBSSL
if (CUtils::GetBoolInput("Would you like ZNC to listen using SSL?", bListenSSL)) {
bListenSSL = true;
CString sPemFile = GetPemLocation();
if (!CFile::Exists(sPemFile)) {
CUtils::PrintError("Unable to locate pem file: [" + sPemFile + "]");
if (CUtils::GetBoolInput("Would you like to create a new pem file now?",
true)) {
WritePemFile();
}
}
} else
bListenSSL = false;
bListenSSL = CUtils::GetBoolInput("Would you like ZNC to listen using SSL?", bListenSSL);
#endif
#ifdef HAVE_IPV6
@@ -632,6 +620,14 @@ bool CZNC::WriteNewConfig(const CString& sConfigFile) {
delete pListener;
} while (!bSuccess);
#ifdef HAVE_LIBSSL
CString sPemFile = GetPemLocation();
if (!CFile::Exists(sPemFile)) {
CUtils::PrintMessage("Unable to locate pem file: [" + sPemFile + "], creating it");
WritePemFile();
}
#endif
vsLines.push_back("<Listener l>");
vsLines.push_back("\tPort = " + CString(uListenPort));
vsLines.push_back("\tIPv4 = true");