This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Integrate mainline
[perl5.git] / t / lib / st-lock.t
index 1e6ae63..694db16 100644 (file)
@@ -1,10 +1,16 @@
 #!./perl
 
-# $Id: lock.t,v 1.0.1.1 2000/09/28 21:44:06 ram Exp $
+# $Id: lock.t,v 1.0.1.3 2000/10/26 17:11:27 ram Exp ram $
 #
 #  @COPYRIGHT@
 #
 # $Log: lock.t,v $
+# Revision 1.0.1.3  2000/10/26 17:11:27  ram
+# patch5: just check $^O, there's no need for the whole Config
+#
+# Revision 1.0.1.2  2000/10/23 18:03:07  ram
+# patch4: protected calls to flock() for dos platform
+#
 # Revision 1.0.1.1  2000/09/28 21:44:06  ram
 # patch2: created.
 #
 
 sub BEGIN {
     chdir('t') if -d 't';
-    @INC = '.';
+    @INC = '.'; 
     push @INC, '../lib';
     require Config; import Config;
     if ($Config{'extensions'} !~ /\bStorable\b/) {
         print "1..0 # Skip: Storable was not built\n";
         exit 0;
     }
-    if (!$Config{'d_flock'} && !$Config{'d_fcntl'} && !$Config{'d_lockf'}) {
+    if (!$Config{'d_flock'} &&
+       !$Config{'d_fcntl_can_lock'} &&
+       !$Config{'d_lockf'}) {
         print "1..0 # Skip: no flock or flock emulation on this platform\n";
         exit 0;
     }
-    if ($Config{'osname'} eq 'dos') {
+    if ($^O eq 'dos') {
        print "1..0 # Skip: fcntl/flock emulation broken on this platform\n";
        exit 0;
     }