--- IO-AIO/AIO.pm 2005/12/26 18:31:12 1.44 +++ IO-AIO/AIO.pm 2005/12/29 15:44:13 1.47 @@ -69,7 +69,7 @@ use Fcntl (); BEGIN { - $VERSION = '1.7'; + $VERSION = '1.72'; @EXPORT = qw(aio_sendfile aio_read aio_write aio_open aio_close aio_stat aio_lstat aio_unlink aio_rmdir aio_readdir aio_scandir aio_symlink @@ -239,7 +239,7 @@ Asynchronously rmdir (delete) a directory and call the callback with the result code. -=item aio_readdir $pathname $callback->($entries) +=item aio_readdir $pathname, $callback->($entries) Unlike the POSIX call of the same name, C reads an entire directory (i.e. opendir + readdir + closedir). The entries will not be @@ -300,7 +300,7 @@ # stat once aio_stat $path, sub { - $cb->() if $_[0]; + return $cb->() if $_[0]; my $hash1 = join ":", (stat _)[0,1,3,7,9]; # read the directory entries @@ -347,7 +347,7 @@ # finished undef $statcb; undef $schedcb; - $cb->(\@dirs, \@nondirs); + $cb->(\@dirs, \@nondirs) if $cb; undef $cb; } };