Development info?

Julian Field MailScanner at
Sun Aug 24 21:28:19 IST 2008

Hugo van der Kooij wrote:
> Another issue is error reporting. The only error you get at startup is
> about the last line tht might be missing. But just about any mistake
> will show that message. Can the error report be made more specific?
If you run MailScanner --lint you will get plenty of extra error 
reporting about your Custom Functions and why they won't compile. Take a 
look at this snippet of output I just tried, when I put a syntax error 

[root at alegria CustomFunctions]# perl -c
Number found where operator expected at line 104, near "1"
    (Missing semicolon on previous line?)
syntax error at line 104, near "1" had compilation errors.
[root at alegria CustomFunctions]# MailScanner --lint

Currently you are using no virus scanners.
This is probably not what you want.

In your /etc/MailScanner/MailScanner.conf file, set
    Virus Scanners = clamav
Then download
Unpack it, "cd" into the directory and run ./

Trying to setlogsock(unix)
Skipping Custom Function file as its name does not 
end in .pm or .pl
Number found where operator expected at 
/usr/lib/MailScanner/MailScanner/CustomFunctions/ line 104, 
near "1"
    (Missing semicolon on previous line?)
Could not use Custom Function code 
/usr/lib/MailScanner/MailScanner/CustomFunctions/, it could 
not be "require"d. Make sure the last line of the file says "1;" at 
/usr/lib/MailScanner/MailScanner/ line 624

So as you see it prints out the Perl errors just above the "Could not 
use Custom Function code" line near the bottom. What more do you want me 
to add?


Julian Field MEng CITP CEng
Buy the MailScanner book at

MailScanner customisation, or any advanced system administration help?
Contact me at Jules at Jules.FM

PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
PGP public key:

This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

More information about the MailScanner mailing list