The script file contains
export LD_LIBRARY_PATH=./lib/
echo "Line 1"
./LiveMonitor
echo "Line 2"
The output is Line 1 After closing Line 1 Line 2
What can cause such behaviour ?
Could be a display cache. Its actually just putting Line1,Line2, but the process being closed could trigger a partial refresh, which could cause the complete script output to be redrawn (now without the new-line from calling the script). Pipe the output of the script to a file and see if there are still Line1 twice before Line2.
./myscript.sh > log.txt
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.