Prechádzať zdrojové kódy

UI: Fix inconsistencies in FindProtocol

- Fallback to RTMP if custom server is empty.
- Check if RTMPS is supported since OBS Studio can be built without it.
tytan652 2 rokov pred
rodič
commit
d529f2c35f
1 zmenil súbory, kde vykonal 5 pridanie a 2 odobranie
  1. 5 2
      UI/window-basic-settings-stream.cpp

+ 5 - 2
UI/window-basic-settings-stream.cpp

@@ -533,11 +533,14 @@ void OBSBasicSettings::ServiceChanged()
 
 QString OBSBasicSettings::FindProtocol()
 {
-	if (IsCustomService() && !ui->customServer->text().isEmpty()) {
+	if (IsCustomService()) {
+		if (ui->customServer->text().isEmpty())
+			return QString("RTMP");
 
 		QString server = ui->customServer->text();
 
-		if (server.startsWith("rtmps://"))
+		if (obs_is_output_protocol_registered("RTMPS") &&
+		    server.startsWith("rtmps://"))
 			return QString("RTMPS");
 
 		if (server.startsWith("ftl://"))