1 |
commit: 74d377662c78a5d6feef51e6bd9bbd38f9acc85c |
2 |
Author: Fabian Groffen <grobian <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Jul 29 08:08:06 2016 +0000 |
4 |
Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Jul 29 08:08:06 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=74d37766 |
7 |
|
8 |
scripts/rsync-generation/refresh-mirror: use available filedescriptor iso fixed 3 |
9 |
|
10 |
scripts/rsync-generation/refresh-mirror.sh | 5 ++++- |
11 |
1 file changed, 4 insertions(+), 1 deletion(-) |
12 |
|
13 |
diff --git a/scripts/rsync-generation/refresh-mirror.sh b/scripts/rsync-generation/refresh-mirror.sh |
14 |
index 24643ca..bcfdd8f 100755 |
15 |
--- a/scripts/rsync-generation/refresh-mirror.sh |
16 |
+++ b/scripts/rsync-generation/refresh-mirror.sh |
17 |
@@ -25,8 +25,11 @@ else |
18 |
# && ./gen-timing-rsync0-graph.sh \ |
19 |
# && popd > /dev/null |
20 |
} |
21 |
- (((genandpush | tee -a "${LOGFILE}") 3>&1 1>&2 2>&3 \ |
22 |
+ # get a free filedescriptor in FD |
23 |
+ exec {FD}>/tmp/rsync-master-busy |
24 |
+ (((genandpush | tee -a "${LOGFILE}") ${FD}>&1 1>&2 2>&${FD} \ |
25 |
| tee -a "${LOGFILE}") 2> /dev/null) |
26 |
echo "generation done $(date)" >> ${LOGFILE} |
27 |
+ exec {FD}>&- |
28 |
rm -f /tmp/rsync-master-busy |
29 |
fi |