diff options
author | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2011-08-04 20:31:24 +0400 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2011-08-04 20:31:24 +0400 |
commit | 3f96e6a7a317e70b85b32de4aa06681c11d79006 (patch) | |
tree | 70343e3fb1a43d29d9c4f454fa47b2dcad6249ad /src/lmtp_proto.c | |
parent | 6b86782ce21caad081d41f54ef10233a8e757189 (diff) | |
download | rspamd-3f96e6a7a317e70b85b32de4aa06681c11d79006.tar.gz rspamd-3f96e6a7a317e70b85b32de4aa06681c11d79006.zip |
Fix signness in arithmetic operations.
Diffstat (limited to 'src/lmtp_proto.c')
-rw-r--r-- | src/lmtp_proto.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lmtp_proto.c b/src/lmtp_proto.c index de2305924..a8c462b03 100644 --- a/src/lmtp_proto.c +++ b/src/lmtp_proto.c @@ -111,7 +111,7 @@ read_lmtp_input_line (struct rspamd_lmtp_proto *lmtp, f_str_t * line) { gchar *c, *rcpt; f_str_t fstr; - guint i = 0, l = 0, size; + gint i = 0, l = 0, size; switch (lmtp->state) { case LMTP_READ_LHLO: @@ -125,7 +125,7 @@ read_lmtp_input_line (struct rspamd_lmtp_proto *lmtp, f_str_t * line) i += lhlo_command.len; c = line->begin + i; /* Skip spaces */ - while (g_ascii_isspace (*c) && i < line->len) { + while (g_ascii_isspace (*c) && i < (gint)line->len) { i++; c++; } @@ -222,9 +222,9 @@ read_lmtp_input_line (struct rspamd_lmtp_proto *lmtp, f_str_t * line) else { l = lmtp->task->msg->len; size = lmtp->task->msg->size; - if (l + line->len > size) { + if ((gint)(l + line->len) > size) { /* Grow buffer */ - if (line->len > size) { + if ((gint)line->len > size) { size += line->len << 1; } else { |