<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    On 19/03/2015 16:20, Sylvain Viart wrote:<br>
    <blockquote cite="mid:550AE933.6050109@opensource-expert.com"
      type="cite">
      <pre wrap="">I would like to know which rules will match first?

Where is it handled in the code?
</pre>
    </blockquote>
    <br>
    If I'm right it is handled by: <br>
    <br>
    mailscanner/bin/MailScanner/SweepOther.pm<br>
    sub ScanBatch {<br>
    <br>
    And <i>Filename Rules</i> seems to be applied <b>before</b> <i>Filetype
      Rules</i>:<br>
    <br>
    <a
href="https://github.com/MailScanner/v4/blob/master/mailscanner/bin/MailScanner/SweepOther.pm#L154">https://github.com/MailScanner/v4/blob/master/mailscanner/bin/MailScanner/SweepOther.pm#L154</a><br>
    <br>
    The following at the end which seems to handle the Filetype Rules<br>
    <br>
    <a
href="https://github.com/MailScanner/v4/blob/master/mailscanner/bin/MailScanner/SweepOther.pm#L427">https://github.com/MailScanner/v4/blob/master/mailscanner/bin/MailScanner/SweepOther.pm#L427</a><br>
    <br>
    counter += CheckFileContentTypes($batch)<br>
    <br>
    Someone confirms?<br>
    <br>
    Regards.<br>
    Sylvain.<br>
  </body>
</html>