From aea8da872bbe5400f02af466aa30dd097ca5d46c Mon Sep 17 00:00:00 2001 From: Guilhem Moulin Date: Fri, 6 Mar 2020 02:12:38 +0100 Subject: tools/apply-colormap:serial_send(): Backup and restore IFS. --- tools/apply-colormap | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tools') diff --git a/tools/apply-colormap b/tools/apply-colormap index dd35844..07b0470 100755 --- a/tools/apply-colormap +++ b/tools/apply-colormap @@ -79,7 +79,7 @@ palette() { } serial_send() { - local fd + local fd old_IFS="$IFS" exec {fd}<"$DEVICE_PATH" "$@" >"$DEVICE_PATH" while IFS= read -r -u "$fd" x; do @@ -87,6 +87,7 @@ serial_send() { [ "$x" != "." ] || break printf "%s\\n" "$x" done + IFS="$old_IFS" {fd}<&- } -- cgit v1.2.3