#
# Permission to use, copy, modify, distribute, and sell this software and its
# documentation for any purpose is hereby granted without fee, provided that
#
# Permission to use, copy, modify, distribute, and sell this software and its
# documentation for any purpose is hereby granted without fee, provided that
-import Fcntl ':mode' unless defined &S_ISDIR; # but it is here in Perl 5.8
+import Fcntl ':mode' unless defined &S_ISUID; # but it is here in Perl 5.8
+ # but in Perl 5.10, both of these load, and cause errors!
+ # So we have to check for S_ISUID instead of S_ISDIR? WTF?
use bytes; # Larry can take Unicode and shove it up his ass sideways.
# Perl 5.8.0 causes us to start getting incomprehensible
# errors about UTF-8 all over the place without this.
my $progname = $0; $progname =~ s@.*/@@g;
use bytes; # Larry can take Unicode and shove it up his ass sideways.
# Perl 5.8.0 causes us to start getting incomprehensible
# errors about UTF-8 all over the place without this.
my $progname = $0; $progname =~ s@.*/@@g;
my $file = $cache_file_name;
open (CACHE_FILE, "+>>$file") || error ("unable to write $file: $!");
flock (CACHE_FILE, LOCK_EX) || error ("unable to lock $file: $!");
seek (CACHE_FILE, 0, 0) || error ("unable to rewind $file: $!");
my $file = $cache_file_name;
open (CACHE_FILE, "+>>$file") || error ("unable to write $file: $!");
flock (CACHE_FILE, LOCK_EX) || error ("unable to lock $file: $!");
seek (CACHE_FILE, 0, 0) || error ("unable to rewind $file: $!");