-
-
Save fwaggle/584cf2a96002af9d0f64 to your computer and use it in GitHub Desktop.
Ugly hack to fix suggestversion when set anywhere but the .ini
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/murmur/Server.cpp b/src/murmur/Server.cpp | |
index e50fbb2..410a9fc 100644 | |
--- a/src/murmur/Server.cpp | |
+++ b/src/murmur/Server.cpp | |
@@ -43,6 +43,7 @@ | |
#include "PacketDataStream.h" | |
#include "ServerDB.h" | |
#include "ServerUser.h" | |
+#include "Version.h" | |
#ifdef USE_BONJOUR | |
#include "BonjourServer.h" | |
@@ -386,7 +387,7 @@ void Server::readParams() { | |
bAllowPing = getConf("allowping", bAllowPing).toBool(); | |
bCertRequired = getConf("certrequired", bCertRequired).toBool(); | |
- qvSuggestVersion = getConf("suggestversion", qvSuggestVersion); | |
+ qvSuggestVersion = MumbleVersion::getRaw(getConf("suggestversion", qvSuggestVersion).toString()); | |
if (qvSuggestVersion.toUInt() == 0) | |
qvSuggestVersion = QVariant(); | |
@@ -507,7 +508,7 @@ void Server::setLiveConf(const QString &key, const QString &value) { | |
else if (key == "channelname") | |
qrChannelName=!v.isNull() ? QRegExp(v) : Meta::mp.qrChannelName; | |
else if (key == "suggestversion") | |
- qvSuggestVersion = ! v.isNull() ? (v.isEmpty() ? QVariant() : v) : Meta::mp.qvSuggestVersion; | |
+ qvSuggestVersion = ! v.isNull() ? (v.isEmpty() ? QVariant() : MumbleVersion::getRaw(v)) : Meta::mp.qvSuggestVersion; | |
else if (key == "suggestpositional") | |
qvSuggestPositional = ! v.isNull() ? (v.isEmpty() ? QVariant() : v) : Meta::mp.qvSuggestPositional; | |
else if (key == "suggestpushtotalk") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment