]> xenbits.xensource.com Git - people/royger/osstest.git/commitdiff
mg-transient-task: Put the ownd fd on a high fd, say, 114
authorIan Jackson <ian.jackson@eu.citrix.com>
Tue, 21 May 2019 09:59:14 +0000 (10:59 +0100)
committerIan Jackson <ian.jackson@eu.citrix.com>
Fri, 21 Jun 2019 14:21:00 +0000 (15:21 +0100)
This avoids clashes with other shell scripts' etc. fds.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
---
v2: New patch

mg-transient-task
tcl/JobDB-Executive.tcl

index 2b3b315e8ff6c03cb3d8572dd62084c0b85c8457..ce5180ff2ae69b4d61e690b16c0b4cf910b13102 100755 (executable)
@@ -22,7 +22,10 @@ package require Tclx
 
 source ./tcl/daemonlib.tcl
 
-jobdb::become-task [string range "$argv" 0 50]
+set ownerqueue [jobdb::become-task [string range "$argv" 0 50]]
+dup $ownerqueue file114
+close $ownerqueue
+
 exec 2>@ stderr perl -I. -e {
         use Osstest;
         use Osstest::Executive;
index 4f3409a9f94456fb98a805f03345a946841cf414..56b61825680c47438c83880d02f884360cb80835 100644 (file)
@@ -435,6 +435,7 @@ proc become-task {comment} {
                AND refkey = [pg_quote [lindex $refinfo 1]]
         "
     }
+    return $ownerqueue
 }
 
 proc preserve-task {seconds} {