| Next | Welcome to my ~/bin | 94 | 
        sub read_spoold {
          my $dir = shift;
          local *SPOOLD;
          unless (opendir SPOOLD, $dir) {
            temp_error("Couldn't read spool directory $dir: $!", 10);
          }
          my @f = grep $_ ne $CONF{curfile}, grep !/^\./, readdir SPOOLD;
          print STDERR "queue contains ", scalar(@f), " items\n" 
            if $CONF{debug_printd};
          map $_->[0], sort { $b->[1] <=> $a->[1] } map [$_, -M], @f;
        }
 
The queue policy is determined here
Jobs are sorted in order of arrival
But it would be easy to promote priority jobs to the top of the queue
There's a bug here
Someone could use touch to promote their job to the top of the queue
For some reason I thought touch only went forward in time
I haven't bothered to solve this yet either
| Next | Menu |  | Copyright © 2005 M. J. Dominus |