Fixed per ikegami's reply at http://www.perlmonks.org/?node_id=531005
rkinyon [Fri, 17 Feb 2006 17:32:12 +0000 (17:32 +0000)]
lib/DBM/Deep.pm

index 84be3bc..e092cd9 100644 (file)
@@ -259,7 +259,7 @@ sub _open {
 
     if ($self->root->{autoflush}) {
 #        $self->fh->autoflush();
-        my $old = select( $fh );
+        my $old = select $fh;
         $|++;
         select $old;
     }
@@ -283,8 +283,9 @@ sub _open {
 
 #        $fh->flush();
         my $old_fh = select $fh;
-        local $| = 1;
-        print $fh q{};
+        my $old_af = $|;
+        $| = 1;
+        $| = $old_af;
         select $old_fh;
 
         return 1;