aboutsummaryrefslogtreecommitdiff
path: root/src/modules/m_dnsbl.cpp
diff options
context:
space:
mode:
authorGravatar Dominic Hamon2021-05-30 20:37:54 +0100
committerGravatar GitHub2021-05-30 20:37:54 +0100
commit02340285c564a7e82105137192d46d554a6fce3a (patch)
tree696d1a6249841de62c3fed70310c2a347fc66732 /src/modules/m_dnsbl.cpp
parentAdd a workaround for a bug in GitHub Actions. (diff)
Added -Wshorten-64-to-32 and fixed all warnings.
Diffstat (limited to 'src/modules/m_dnsbl.cpp')
-rw-r--r--src/modules/m_dnsbl.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/modules/m_dnsbl.cpp b/src/modules/m_dnsbl.cpp
index 76ca47bb4..f61998981 100644
--- a/src/modules/m_dnsbl.cpp
+++ b/src/modules/m_dnsbl.cpp
@@ -126,7 +126,7 @@ public:
{
type = Type::BITMASK;
- bitmask = tag->getUInt("bitmask", 0, 0, UINT_MAX);
+ bitmask = static_cast<unsigned int>(tag->getUInt("bitmask", 0, 0, UINT_MAX));
records = 0;
}
else if (stdalgo::string::equalsci(typestr, "record"))
@@ -149,7 +149,7 @@ public:
}
reason = tag->getString("reason", "Your IP (%ip%) has been blacklisted by a DNSBL.", 1, ServerInstance->Config->Limits.MaxLine);
- timeout = tag->getDuration("timeout", 0, 1, 60);
+ timeout = static_cast<unsigned int>(tag->getDuration("timeout", 0, 1, 60));
markident = tag->getString("ident");
markhost = tag->getString("host");
xlineduration = tag->getDuration("duration", 60*60, 1);
@@ -187,7 +187,7 @@ class DNSBLResolver : public DNS::Request
return;
}
- int i = countExt.Get(them);
+ intptr_t i = countExt.Get(them);
if (i)
countExt.Set(them, i - 1);
@@ -358,7 +358,7 @@ class DNSBLResolver : public DNS::Request
if (!them || them->client_sa != theirsa)
return;
- int i = countExt.Get(them);
+ intptr_t i = countExt.Get(them);
if (i)
countExt.Set(them, i - 1);