]> jfr.im git - solanum.git/commitdiff
Use const hook data where possible
authorSimon Arlott <sa.me.uk>
Sun, 30 Oct 2016 12:36:50 +0000 (12:36 +0000)
committerSimon Arlott <sa.me.uk>
Sun, 30 Oct 2016 12:36:50 +0000 (12:36 +0000)
core/m_nick.c: In function `change_remote_nick':
core/m_nick.c:745: warning: assignment discards qualifiers from pointer target type

include/hook.h
modules/core/m_nick.c

index 72cc9fdd2f01292b11ee1f2f2e1b39d920f00838..eb8c1a6d47b85a39fe931faff9d3b75826b789b4 100644 (file)
@@ -82,7 +82,7 @@ typedef struct
 {
        struct Client *client;
        struct Channel *chptr;
-       char *key;
+       const char *key;
 } hook_data_channel_activity;
 
 typedef struct
index ec57b93a97e52cab5828cf201941e0d6f0b92251..0b2481e4501ca3c3a29374fec4f0bbf54519a25f 100644 (file)
@@ -624,7 +624,7 @@ change_local_nick(struct Client *client_p, struct Client *source_p,
        struct Channel *chptr;
        char note[NICKLEN + 10];
        int samenick;
-       hook_data hook_info;
+       hook_cdata hook_info;
 
        if (dosend)
        {
@@ -731,7 +731,7 @@ change_remote_nick(struct Client *client_p, struct Client *source_p,
 {
        struct nd_entry *nd;
        int samenick = irccmp(source_p->name, nick) ? 0 : 1;
-       hook_data hook_info;
+       hook_cdata hook_info;
 
        /* client changing their nick - dont reset ts if its same */
        if(!samenick)