summaryrefslogtreecommitdiffstats
path: root/lib/OpenSLX/Utils.pm
diff options
context:
space:
mode:
authorOliver Tappe2009-06-09 19:59:03 +0200
committerOliver Tappe2009-06-09 19:59:03 +0200
commit2efbbd9e16228e103c15971492f43bf90e6f93cd (patch)
treecc12c239185c57b014791e110d7fd76ee3258b0c /lib/OpenSLX/Utils.pm
parentuse distroutils in xserver plugin (diff)
downloadcore-2efbbd9e16228e103c15971492f43bf90e6f93cd.tar.gz
core-2efbbd9e16228e103c15971492f43bf90e6f93cd.tar.xz
core-2efbbd9e16228e103c15971492f43bf90e6f93cd.zip
* fixed pretty stupid bug that involved mixed use of bufferd/non-buffered IO
which caused locks to hang even in the same process-group (for which they should be recursable) - closes #451 git-svn-id: http://svn.openslx.org/svn/openslx/openslx/trunk@2943 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'lib/OpenSLX/Utils.pm')
-rw-r--r--lib/OpenSLX/Utils.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/OpenSLX/Utils.pm b/lib/OpenSLX/Utils.pm
index 5b6a3eb0..096b6e5f 100644
--- a/lib/OpenSLX/Utils.pm
+++ b/lib/OpenSLX/Utils.pm
@@ -624,7 +624,7 @@ sub grabLock
local $| = 1;
my $waiting;
while(!(sysopen($lockFH, $lockFile, O_RDWR | O_CREAT | O_EXCL)
- && print $lockFH getpgrp() . "\n")) {
+ && syswrite($lockFH, getpgrp() . "\n"))) {
if ($! == 13) {
die _tr(
qq[Unable to create lock "%s", giving up!], $lockFile