--- /root/unstable/mailscanner/mailscanner/bin/MailScanner/Sendmail.pm	Wed Nov  6 14:45:15 2002
+++ Sendmail.pm	Thu Nov  7 18:48:46 2002
@@ -827,13 +830,14 @@
   $dirhandle->open($dir)
     or MailScanner::Log::DieLog("Cannot read queue directory $dir");
 
-  # Check there are no subdirectories
+  # Check there are no q\d or qf subdirectories
   while($f = $dirhandle->read()) {
     # 2nd half of the line for SuSE Linux setups which put .hoststat
     # directory inside the queue!
     next if $f =~ /^\.\.?$/ || $f =~ /^\.hoststat/;
     # Delete core files
     $f =~ /^core$/ and unlink "core";
+    next unless $f =~ /^q[0-9f]$/;
     # Also needs untaint... sledgehammer. nut.
     $f =~ /(.*)/;
     MailScanner::Log::DieLog("Queue directory %s cannot contain sub-" .