Subject: | Remove temporary directory only if it was NOT an automatically generated one! |
Date: | Thu, 17 Oct 2013 22:35:29 +0900 |
To: | bug-Parallel-ForkManager [...] rt.cpan.org |
From: | Shoichi Kaji <skaji [...] outlook.com> |
Hi,
I'm using Parallel-ForkManager-1.05.
Changes file states:
1.05 Wed Sep 18 10:53:33 2013
- Remove temporary directory only if it was an automatically
generated one. (reported by Manuel Jeckelmann)
But, Parallel-ForkManager-1.05 works in quite the opposite way:
Remove temporary directory only if it was NOT an automatically generated one!
The following patch would fix this issue:
diff --git a/lib/Parallel/ForkManager.pm b/lib/Parallel/ForkManager.pm
index 92b2f68..1219da5 100644
--- a/lib/Parallel/ForkManager.pm
+++ b/lib/Parallel/ForkManager.pm
@@ -453,7 +453,7 @@ sub new {
processes => {},
in_child => 0,
parent_pid => $$,
- auto_cleanup => ($tempdir ? 1 : 0),
+ auto_cleanup => ($tempdir ? 0 : 1),
};
Thank you.
Shoichi Kaji