Bug 7999 - Plugins DCC.pm, FreeMail.pm, Phishing.pm, URIDetail.pm: return undef after got_hit/rule_ready
Summary: Plugins DCC.pm, FreeMail.pm, Phishing.pm, URIDetail.pm: return undef after go...
Status: RESOLVED FIXED
Alias: None
Product: Spamassassin
Classification: Unclassified
Component: Plugins (show other bugs)
Version: 4.0.0
Hardware: All All
: P2 trivial
Target Milestone: Undefined
Assignee: SpamAssassin Developer Mailing List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-05-30 13:21 UTC by Michael Storz
Modified: 2022-06-03 05:46 UTC (History)
3 users (show)



Attachment Type Modified Status Actions Submitter/CLA Status
return undef after call to got_hit/rule_ready patch None Michael Storz [NoCLA]

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Storz 2022-05-30 13:21:08 UTC
After an explicit call to got_hit or rule_ready the return value should be undef instead of 1 or 0, otherwise another implicit call to got_hit or rule_ready would be triggered, which is superfluous.
Comment 1 Michael Storz 2022-05-30 13:25:33 UTC
Created attachment 5785 [details]
return undef after call to got_hit/rule_ready
Comment 2 Sidney Markowitz 2022-05-30 13:54:17 UTC
(In reply to Michael Storz from comment #1)
> Created attachment 5785 [details]

Hi Michael, could you please submit an ICLA if you are going to submit patches?
I expect that Henrik is in a better position to look at and evaluate the patch itself, but I'm handling the bureaucratic details required by ASF of making sure that all submitted code comes from someone who has filed an ICLA.
See https://www.apache.org/licenses/contributor-agreements.html

Thanks
Comment 3 Henrik Krohns 2022-05-30 14:38:18 UTC
"superfluous" is completely correct, as this would be no blocker for 4.0.0 or make any difference how things work.

Likely some of these can be even rewritten for better logic, as FreeMail etc is not even async, there is no point returning undef anyway.

I'll take this just as a hint on what to work on, so this should require no ICLA as I'm not applying it.
Comment 4 Henrik Krohns 2022-06-03 05:46:54 UTC
Revision 1901578
Revision 1901579
Revision 1901581