aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Chigot <chigot@adacore.com>2025-03-31 10:42:43 +0200
committerClément Chigot <chigot@adacore.com>2025-04-01 10:14:54 +0200
commit71320db6509e0893607e9343b5af56a8c130a2ed (patch)
tree8ac53e25b149922d7760f529778d83056c1e70c3
parentc27e4f5273cd4d4e8714f9968ddc5cb900f0f528 (diff)
downloadbinutils-71320db6509e0893607e9343b5af56a8c130a2ed.zip
binutils-71320db6509e0893607e9343b5af56a8c130a2ed.tar.gz
binutils-71320db6509e0893607e9343b5af56a8c130a2ed.tar.bz2
binutils/testsuite: don't tail the same input and output file
The output file could be created before the input is gathered by tail, erasing the later before it's being proceeded. This happened on rare cases when performing remote tests on Ubuntu 24.04.
-rw-r--r--binutils/testsuite/binutils-all/objdump.exp6
1 files changed, 3 insertions, 3 deletions
diff --git a/binutils/testsuite/binutils-all/objdump.exp b/binutils/testsuite/binutils-all/objdump.exp
index bddb0cb..f3142b1 100644
--- a/binutils/testsuite/binutils-all/objdump.exp
+++ b/binutils/testsuite/binutils-all/objdump.exp
@@ -595,8 +595,8 @@ if { ![is_elf_format] } then {
send_log "\n"
}
- set got [remote_exec host "tail -n +4 tmpdir/objdump.out" "" "/dev/null" "tmpdir/objdump.out"]
- set output [remote_upload host tmpdir/objdump.out]
+ set got [remote_exec host "tail -n +4 tmpdir/objdump.out" "" "/dev/null" "tmpdir/objdump.tail"]
+ set output [remote_upload host tmpdir/objdump.tail]
if ![file size $output] then {
# If the output file is empty, then this target does not
@@ -606,7 +606,7 @@ if { ![is_elf_format] } then {
return
}
- if { [regexp_diff tmpdir/objdump.out $srcdir/$subdir/dw5-op.W] } then {
+ if { [regexp_diff tmpdir/objdump.tail $srcdir/$subdir/dw5-op.W] } then {
fail "objdump -Wi for DW_OP_*"
} else {
pass "objdump -Wi for DW_OP_*"