From 4a55dedadc0fb80d4dfa9bc8293339e6cfdc6246 Mon Sep 17 00:00:00 2001 From: derrod Date: Sat, 6 Apr 2019 15:35:16 +0200 Subject: [PATCH] UI: Fix bandwidth test flag being saved to stream key Previously enabling and disabling bandwidth testing in a certain order lead to the parameter being included in the stream key that is saved to disk, making it impossible to disable the bandwidth test later on. By doing this properly and using string concatenation instead of modifying (appending to) the key_ value this will no longer happen. --- UI/auth-oauth.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UI/auth-oauth.cpp b/UI/auth-oauth.cpp index 1799ba3f..976bca4d 100644 --- a/UI/auth-oauth.cpp +++ b/UI/auth-oauth.cpp @@ -301,7 +301,7 @@ void OAuthStreamKey::OnStreamConfig() if (bwtest && strcmp(this->service(), "Twitch") == 0) obs_data_set_string(settings, "key", - key_.append("?bandwidthtest=true").c_str()); + (key_ + "?bandwidthtest=true").c_str()); else obs_data_set_string(settings, "key", key_.c_str()); -- GitLab