Bug 5142 - [review] Decimal numbers in Meta Test Math triggers undefined dependency
Summary: [review] Decimal numbers in Meta Test Math triggers undefined dependency
Status: RESOLVED FIXED
Alias: None
Product: Spamassassin
Classification: Unclassified
Component: Rules (show other bugs)
Version: 3.1.4
Hardware: Other other
: P5 normal
Target Milestone: 3.1.8
Assignee: SpamAssassin Developer Mailing List
URL:
Whiteboard: needs 1 vote
Keywords:
Depends on:
Blocks:
 
Reported: 2006-10-20 06:31 UTC by Kevin A. McGrail
Modified: 2007-02-05 09:32 UTC (History)
0 users



Attachment Type Modified Status Actions Submitter/CLA Status
suggested patch patch None Theo Van Dinter [HasCLA]
new suggested patch patch None Theo Van Dinter [HasCLA]

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin A. McGrail 2006-10-20 06:31:05 UTC
A meta test with math such as:

meta            KAM_TIME        ((__KAM_TIME1 + ((__KAM_TIME2 + __KAM_TIME3 +
__KAM_TIME4 + __KAM_TIME5) / 2) + (__KAM_TIME6 * 1.5)) >= 2)

gives this error:

[1177] info: rules: meta test KAM_TIME has undefined dependency '1.5'
Comment 1 Kevin A. McGrail 2006-10-20 06:31:34 UTC
A work around is to use something like __KAM_TIME6 * (3/2)
Comment 2 Theo Van Dinter 2006-12-04 13:50:03 UTC
Ok, I have a patch which will be up shortly.  Interesting while writing this, I
found another bug where rules were required to be at least 2 chars long.  oops.
Comment 3 Theo Van Dinter 2006-12-04 13:50:21 UTC
Created attachment 3762 [details]
suggested patch
Comment 4 Theo Van Dinter 2006-12-04 17:50:13 UTC
Created attachment 3763 [details]
new suggested patch

same as before, but fixes small typo
Comment 5 Daryl C. W. O'Shea 2006-12-08 09:48:40 UTC
+1
Comment 6 Justin Mason 2007-02-05 08:56:32 UTC
+1
Comment 7 Kevin A. McGrail 2007-02-05 09:22:46 UTC
I can't vote but the patch looks good to me.
Comment 8 Theo Van Dinter 2007-02-05 09:32:17 UTC
Sending        lib/Mail/SpamAssassin/Conf/Parser.pm
Sending        lib/Mail/SpamAssassin/Constants.pm
Sending        lib/Mail/SpamAssassin/PerMsgStatus.pm
Transmitting file data ...
Committed revision 503786.