]> jfr.im git - irc/evilnet/x3.git/blobdiff - src/chanserv.c
added extern type to comply with gcc10 change
[irc/evilnet/x3.git] / src / chanserv.c
index 47ea0603dcc1b06e34431dcfacc354d7af5ef071..5931cd0fc731b9654e409ba6bd5d5cdf5bb52b34 100644 (file)
@@ -679,7 +679,7 @@ enum note_visible_type
     NOTE_VIS_PRIVILEGED
 };
 
-struct io_fd *socket_io_fd;
+extern struct io_fd *socket_io_fd;
 extern struct cManagerNode cManager;
 
 struct note_type
@@ -3124,7 +3124,7 @@ static CHANSERV_FUNC(cmd_adduser)
     struct userData *actee;
     struct userData *actor, *real_actor;
     struct handle_info *handle = NULL;
-    struct adduserPending *tmp;
+    //struct adduserPending *tmp;
     unsigned short access_level, override = 0;
 
     REQUIRE_PARAMS(3);
@@ -3168,7 +3168,7 @@ static CHANSERV_FUNC(cmd_adduser)
             else {
                 if(IsInChannel(channel, unode)) {
                    reply("CSMSG_ADDUSER_PENDING", unode->nick);
-                   tmp = add_adduser_pending(channel, unode, access_level);
+                   add_adduser_pending(channel, unode, access_level);
                    send_message_type(1,unode, chanserv, "CSMSG_ADDUSER_PENDING_TARGET", user->nick, channel->name);
                 }
                 /* this results in user must auth AND not in chan errors. too confusing..
@@ -5309,10 +5309,10 @@ static CHANSERV_FUNC(cmd_mode)
 
 static CHANSERV_FUNC(cmd_invite)
 {
-    struct userData *uData;
+    //struct userData *uData;
     struct userNode *invite;
 
-    uData = GetChannelUser(channel->channel_info, user->handle_info);
+    //uData = GetChannelUser(channel->channel_info, user->handle_info);
 
     if(argc > 1)
     {
@@ -7912,7 +7912,7 @@ static CHANSERV_FUNC(cmd_spin)
     /* service ignore */
     else if (!strcasecmp(wheel, "svsignore")) 
     {
-         int gagged;
+         //int gagged;
          int ignoretime = 0;
          char target[HOSTLEN + 13];
 
@@ -7927,7 +7927,7 @@ static CHANSERV_FUNC(cmd_spin)
          strcat(target, user->hostname);
          ignoretime = now + (1 + rand() % 120);
 
-         gagged = gag_create(target, "wheelofabuse", "Reward for spinning the wheel of misfortune!", ignoretime);
+         gag_create(target, "wheelofabuse", "Reward for spinning the wheel of misfortune!", ignoretime);
     }
     /* kick and ban from each channel your in */
     else if (!strcasecmp(wheel, "kickbanall")) 
@@ -8027,7 +8027,7 @@ void eightball(char *outcome, int method, unsigned int seed)
    char ballcolors[50][50] = {
         "blue", "red", "green", "yellow",
         "white", "black", "grey", "brown",
-        "yellow", "pink", "purple", "orange", "teal", "burgandy",
+        "yellow", "pink", "purple", "orange", "teal", "burgundy",
         "fuchsia","turquoise","magenta", "cyan"};
 #define NUMOFLOCATIONS 50
    char balllocations[50][55] = { 
@@ -8933,7 +8933,7 @@ handle_mode(struct chanNode *channel, struct userNode *user, const struct mod_ch
         else if((change->args[ii].mode & (MODE_REMOVE | MODE_BAN)) == MODE_BAN)
         {
             const char *ban = change->args[ii].u.hostmask;
-            if(!bad_channel_ban(channel, user, ban, NULL, NULL))
+            if(bad_channel_ban(channel, user, ban, NULL, NULL) != 1)
                 continue;
             if(!bounce)
                 bounce = mod_chanmode_alloc(change->argc + 1 - ii);
@@ -9367,7 +9367,7 @@ user_read_helper(const char *key, struct record_data *rd, struct chanData *chan)
 static void
 ban_read_helper(const char *key, struct record_data *rd, struct chanData *chan)
 {
-    struct banData *bData;
+    //struct banData *bData;
     char *set, *triggered, *s_duration, *s_expires, *reason, *owner;
     time_t set_time, triggered_time, expires_time;
 
@@ -9398,7 +9398,7 @@ ban_read_helper(const char *key, struct record_data *rd, struct chanData *chan)
     if(!reason || (expires_time && (expires_time < now)))
         return;
 
-    bData = add_channel_ban(chan, key, owner, set_time, triggered_time, expires_time, reason);
+    add_channel_ban(chan, key, owner, set_time, triggered_time, expires_time, reason);
 }
 
 static struct suspended *