From 02340285c564a7e82105137192d46d554a6fce3a Mon Sep 17 00:00:00 2001 From: Dominic Hamon Date: Sun, 30 May 2021 20:37:54 +0100 Subject: Added -Wshorten-64-to-32 and fixed all warnings. --- src/modules/m_ircv3_batch.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/modules/m_ircv3_batch.cpp') diff --git a/src/modules/m_ircv3_batch.cpp b/src/modules/m_ircv3_batch.cpp index eac86a705..7d9cb24ba 100644 --- a/src/modules/m_ircv3_batch.cpp +++ b/src/modules/m_ircv3_batch.cpp @@ -144,7 +144,8 @@ class IRCv3::Batch::ManagerImpl : public Manager if (id >= MAX_BATCHES) return; - batch.Setup(id); + // This cast is safe thanks to the clamping above. + batch.Setup(static_cast(id)); // Set the manager field which Batch::IsRunning() checks and is also used by AddToBatch() // to set the message tag batch.manager = this; -- cgit v1.3.1-10-gc9f91