]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Fix "control reaches end of non-void function" warning.
authorSadie Powell <sadie@witchery.services>
Tue, 28 Jan 2020 16:55:06 +0000 (16:55 +0000)
committerSadie Powell <sadie@witchery.services>
Tue, 28 Jan 2020 18:56:46 +0000 (18:56 +0000)
This is harmless because it will always be set to one of the items
in the TargetType enum.

include/message.h

index 2e3cd9bb1c88c4ef5f819d2eb8837de2cc40e090..322e159d1583d7c2710b4dc35b6f9be4fae1d123 100644 (file)
@@ -167,5 +167,10 @@ class CoreExport MessageTarget
                        case TYPE_SERVER:
                                return *Get<std::string>();
                }
+
+               // We should never reach this point during a normal execution but
+               // handle it just in case.
+               static const std::string target = "*";
+               return target;
        }
 };