Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
ensembl-gh-mirror
ensembl-hive
Commits
61ef5b2e
Commit
61ef5b2e
authored
Sep 08, 2010
by
Leo Gordon
Browse files
try to avoid name and pid collisions
parent
c3974355
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
modules/Bio/EnsEMBL/Hive/Worker.pm
modules/Bio/EnsEMBL/Hive/Worker.pm
+4
-2
No files found.
modules/Bio/EnsEMBL/Hive/Worker.pm
View file @
61ef5b2e
...
...
@@ -397,9 +397,11 @@ sub worker_process_temp_directory {
unless
(
defined
(
$self
->
{'
_tmp_dir
'})
and
(
-
e
$self
->
{'
_tmp_dir
'}))
{
#create temp directory to hold fasta databases
$self
->
{'
_tmp_dir
'}
=
"
/tmp/worker_
$ENV
{'USER'}.$$/
";
my
$username
=
$ENV
{'
USER
'};
my
$worker_id
=
$self
->
worker_id
();
$self
->
{'
_tmp_dir
'}
=
"
/tmp/worker_
${username}
.
${worker_id}
";
mkdir
(
$self
->
{'
_tmp_dir
'},
0777
);
throw
("
unable to create
"
.
$self
->
{'
_tmp_dir
'})
unless
(
-
e
$self
->
{'
_tmp_dir
'});
throw
("
unable to create
a writable directory
"
.
$self
->
{'
_tmp_dir
'})
unless
(
-
w
$self
->
{'
_tmp_dir
'});
}
return
$self
->
{'
_tmp_dir
'};
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment