Disable the throttle limit if negative

Also, invalid values result in -1 being set
This commit is contained in:
louiz’
2018-08-23 22:18:49 +02:00
parent 6c431b64d0
commit 7d0df9b6dd
7 changed files with 23 additions and 10 deletions
+1 -1
View File
@@ -1291,7 +1291,7 @@ bool IrcClient::abort_on_invalid_cert() const
}
#endif
std::size_t IrcClient::get_throttle_limit() const
long int IrcClient::get_throttle_limit() const
{
#ifdef USE_DATABASE
return Database::get_irc_server_options(this->bridge.get_bare_jid(), this->hostname).col<Database::ThrottleLimit>();
+1 -1
View File
@@ -402,7 +402,7 @@ private:
*/
Resolver dns_resolver;
TokensBucket tokens_bucket;
std::size_t get_throttle_limit() const;
long int get_throttle_limit() const;
};