pgbackrest.git / summary / log / commit / refs
commit 7e49e4596f9fdaae102c5caae7dae35c25e75bef
Author: David Steele <david@pgmasters.net>
Date: Sun Aug 09 00:17:33 2015 +0000
Removed dead function wait_for_file().
lib/BackRest/Utility.pm | 33 +--------------------------------
1 file changed, 1 insertion(+), 32 deletions(-)
diff --git a/lib/BackRest/Utility.pm b/lib/BackRest/Utility.pm
index 5e2fe7a4d..8af1738fb 100644
--- a/lib/BackRest/Utility.pm
+++ b/lib/BackRest/Utility.pm
@@ -158,37 +158,6 @@ sub hsleep
return usleep($fSecond * 1000000);
}
-####################################################################################################################################
-# WAIT_FOR_FILE
-####################################################################################################################################
-sub wait_for_file
-{
- my $strDir = shift;
- my $strRegEx = shift;
- my $iSeconds = shift;
-
- my $lTime = time();
- my $hDir;
-
- while ($lTime > time() - $iSeconds)
- {
- if (opendir($hDir, $strDir))
- {
- my @stryFile = grep(/$strRegEx/i, readdir $hDir);
- close $hDir;
-
- if (scalar @stryFile == 1)
- {
- return;
- }
- }
-
- hsleep(.1);
- }
-
- confess &log(ERROR, "could not find $strDir/$strRegEx after ${iSeconds} second(s)");
-}
-
####################################################################################################################################
# COMMON_PREFIX
####################################################################################################################################
@@ -239,7 +208,7 @@ sub file_size_format
}
####################################################################################################################################
-# TIMESTAMP_STRING_GET - Get backrest standard timestamp (or formatted as specified
+# TIMESTAMP_STRING_GET - Get standard timestamp (or formatted as specified)
####################################################################################################################################
sub timestamp_string_get
{
[parent: 45259a487f25]