Salome HOME
projects
/
tools
/
libbatch.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8cbab9e
)
Fix potential deadlock.
author
Ovidiu Mircescu
<ovidiu.mircescu@edf.fr>
Thu, 7 Jun 2018 09:03:55 +0000
(11:03 +0200)
committer
Ovidiu Mircescu
<ovidiu.mircescu@edf.fr>
Thu, 7 Jun 2018 09:03:55 +0000
(11:03 +0200)
src/Local/BatchManager_Local.cxx
patch
|
blob
|
history
diff --git
a/src/Local/BatchManager_Local.cxx
b/src/Local/BatchManager_Local.cxx
index c2c85e0f564cc4e9697ad54295821c86b8b28281..e770599f709538ead9e5cb77ebb9c1a80e54de0d 100644
(file)
--- a/
src/Local/BatchManager_Local.cxx
+++ b/
src/Local/BatchManager_Local.cxx
@@
-464,7
+464,10
@@
namespace Batch {
child = p_ta->launchWin32ChildProcess();
p_ta->pere(child);
#else
+ // LOCK&UNLOCK needed to avoid potential deadlock if a thread holds the lock
+ LOCK_IO
child = fork();
+ UNLOCK_IO
if (child < 0) { // erreur
UNDER_LOCK( LOG("Fork impossible (rc=" << child << ")") );