]> jfr.im git - solanum.git/commitdiff
Fix various compiler warnings.
authorJilles Tjoelker <redacted>
Sat, 27 Mar 2010 19:09:46 +0000 (20:09 +0100)
committerJilles Tjoelker <redacted>
Sat, 27 Mar 2010 19:09:46 +0000 (20:09 +0100)
modules/core/m_ban.c
modules/m_kline.c
src/s_conf.c

index 8481282d5cd3b398e6ecde6678ee72f11a86941f..d966edd4a0d3897b6101ff6623b0c1acbe1849d5 100644 (file)
@@ -187,7 +187,7 @@ ms_ban(struct Client *client_p, struct Client *source_p, int parc, const char *p
        {
                sendto_realops_snomask(SNO_GENERAL, L_ALL,
                                       "Ignoring global %d min. %s from %s%s%s for [%s%s%s]: too few non-wildcard characters",
-                                      (hold - rb_current_time()) / 60,
+                                      (int)((hold - rb_current_time()) / 60),
                                       stype,
                                       IsServer(source_p) ? source_p->name : get_oper_name(source_p),
                                       strcmp(parv[7], "*") ? " on behalf of " : "",
@@ -210,7 +210,7 @@ ms_ban(struct Client *client_p, struct Client *source_p, int parc, const char *p
                sendto_realops_snomask(SNO_GENERAL, L_ALL,
                                       "%s added global %d min. %s%s%s for [%s%s%s] [%s]",
                                       IsServer(source_p) ? source_p->name : get_oper_name(source_p),
-                                      (hold - rb_current_time()) / 60,
+                                      (int)((hold - rb_current_time()) / 60),
                                       stype,
                                       strcmp(parv[7], "*") ? " from " : "",
                                       strcmp(parv[7], "*") ? parv[7] : "",
@@ -220,7 +220,7 @@ ms_ban(struct Client *client_p, struct Client *source_p, int parc, const char *p
                                       parv[parc - 1]);
                ilog(L_KLINE, "%s %s %d %s%s%s %s", parv[1],
                                IsServer(source_p) ? source_p->name : get_oper_name(source_p),
-                               (hold - rb_current_time()) / 60,
+                               (int)((hold - rb_current_time()) / 60),
                                aconf->user ? aconf->user : "",
                                aconf->user ? " " : "",
                                aconf->host,
index d6e22bc58b51676da0fcf49c0caf27a09a2f6e7c..89ba2353344abf36250841176cc4144a36addf53 100644 (file)
@@ -297,7 +297,7 @@ handle_remote_kline(struct Client *source_p, int tkline_time,
                                  ":Please include at least %d non-wildcard "
                                  "characters with the user@host",
                                  ConfigFileEntry.min_nonwildcard);
-               return 0;
+               return;
        }
 
        if(already_placed_kline(source_p, user, host, tkline_time))
index cfd6048d4521c369bd7fdf95e72586c882526ce6..dc733430fdb92c6c5f60134563cbae2c9c8ad7c8 100644 (file)
@@ -1261,7 +1261,7 @@ get_user_ban_reason(struct ConfItem *aconf)
                rb_snprintf(reasonbuf, sizeof reasonbuf,
                                "Temporary %c-line %d min. - ",
                                aconf->status == CONF_DLINE ? 'D' : 'K',
-                               (aconf->hold - aconf->created) / 60);
+                               (int)((aconf->hold - aconf->created) / 60));
        else
                reasonbuf[0] = '\0';
        if (aconf->passwd)