mirror of
https://github.com/anope/anope.git
synced 2026-07-10 03:03:13 +02:00
Replaced some static_casts related to modes with dynamic_cast - its a bit safer
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2715 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
+1
-1
@@ -212,7 +212,7 @@ class CommandCSSet : public Command
|
||||
|
||||
if (cm->Type == MODE_PARAM)
|
||||
{
|
||||
cmp = static_cast<ChannelModeParam *>(cm);
|
||||
cmp = dynamic_cast<ChannelModeParam *>(cm);
|
||||
|
||||
if (!modeparams.GetToken(param))
|
||||
continue;
|
||||
|
||||
@@ -445,7 +445,7 @@ void defconParseModeString(const char *str)
|
||||
|
||||
if (cm->Type == MODE_PARAM)
|
||||
{
|
||||
cmp = static_cast<ChannelModeParam *>(cm);
|
||||
cmp = dynamic_cast<ChannelModeParam *>(cm);
|
||||
|
||||
if (!ss.GetToken(param))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user