as decimal.
-$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.450 2007/01/02 11:25:00 ph10 Exp $
+$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.451 2007/01/08 11:56:41 ph10 Exp $
Change log file for Exim from version 4.21
-------------------------------------------
+Exim version 4.66
+-----------------
+
+PH/01 Two more bugs that were introduced by 4.64/PH/07, in addition to the one
+ fixed by 4.65/MH/01 (is this a record?) are fixed:
+
+ (i) An empty string was always treated as zero by the numeric comparison
+ operators. This behaviour has been restored.
+
+ (ii) It is documented that the numeric comparison operators always treat
+ their arguments as decimal numbers. This was broken in that numbers
+ starting with 0 were being interpreted as octal.
+
+ While fixing these problems I realized that there was another issue that
+ hadn't been noticed. Values of message_size_limit (both the global option
+ and the transport option) were treated as octal if they started with 0.
+ The documentation was vague. These values are now always treated as
+ decimal, and I will make that clear in the documentation.
+
+
Exim version 4.65
-----------------
-/* $Cambridge: exim/src/src/expand.c,v 1.75 2007/01/08 10:50:18 ph10 Exp $ */
+/* $Cambridge: exim/src/src/expand.c,v 1.76 2007/01/08 11:56:41 ph10 Exp $ */
/*************************************************
* Exim - an Internet mail transport agent *
if (!isalpha(name[0]) && yield != NULL)
{
- num[i] = expand_string_integer(sub[i], FALSE);
- if (expand_string_message != NULL) return NULL;
+ if (sub[i][0] == 0)
+ {
+ num[i] = 0;
+ DEBUG(D_expand)
+ debug_printf("empty string cast to zero for numerical comparison\n");
+ }
+ else
+ {
+ num[i] = expand_string_integer(sub[i], FALSE);
+ if (expand_string_message != NULL) return NULL;
+ }
}
}
errno = 0;
expand_string_message = NULL; /* Indicates no error */
-value = strtol(CS s, CSS &endptr, 0);
+value = strtol(CS s, CSS &endptr, 10);
if (endptr == s)
{
#! /usr/bin/perl -w
-# $Cambridge: exim/test/runtest,v 1.19 2006/11/14 16:40:36 ph10 Exp $
+# $Cambridge: exim/test/runtest,v 1.20 2007/01/08 11:56:41 ph10 Exp $
###############################################################################
# This is the controlling script for the "new" test suite for Exim. It should #
# Start by initializing some global variables
-$testversion = "4.64 (05-Sep-06)";
+$testversion = "4.66 (08-Jan-07)";
$cf = "bin/cf";
$cr = "\r";
5>3z: ${if >{5 } {3z }{y}{n}}
5>a: ${if >{ 5 } {a}{y}{n}}
+>0: ${if > {}{0}{y}{n}}
+=: ${if = {}{}{y}{n}}
+-2<: ${if < {-2}{}{y}{n}}
+08>07: ${if > {08}{07}{y}{n}}
+011=11: ${if = {011}{11}{y}{n}}
+
def:y ${if def:tod_log{y}{n}}
def:n ${if def:host{y}{n}}
def:f ${if def:post{y}{n}}
> Failed: invalid integer "3z "
> Failed: integer expected but "a" found
>
+> >0: n
+> =: y
+> -2<: y
+> 08>07: y
+> 011=11: y
+>
> def:y y
> def:n n
> Failed: unknown variable "post" after "def:"