diff options
Diffstat (limited to 'src/misc.c')
-rw-r--r-- | src/misc.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/misc.c b/src/misc.c index 5e5038252..3df45aab5 100644 --- a/src/misc.c +++ b/src/misc.c @@ -1135,4 +1135,16 @@ char *str_signed(unsigned char *str) return nstr; } +/** + * Strip the mode prefix from the given string. + * Useful for using the modes stored in things like ircd->ownerset etc.. + **/ + +char *stripModePrefix(const char *str) { + if(str) { + return strdup(str+1); + } + return NULL; +} + /* EOF */ |