Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 26 Jul 2008 00:35:10 +0200
From:      "Tanel Rebane" <flagel@gmail.com>
To:        freebsd-ports-bugs@freebsd.org
Subject:   "Interrupted system call"-output with Bash 3.2.39(1)-release
Message-ID:  <e73893440807251535k8178035hc162e021e1d0da7c@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hello good people,

I've come across a problem that I can't seem to find a solution to. It
seems to me that this might be a bug.

The following shell script:
#!/usr/bin/env bash
for (( q = 0 ; q < 10 ; q++ )); do
	while read -d '' z; do result+=("$z"); done < <(printf "%s\000\n" foo
| grep -a 'foo')
	# Uncommenting sleep will fix the problem
	# sleep 1
done
#printf "%s\n" "${result[@]}"

Results in the following output:
[22:43:09][flagel@rose ~/private/system] ./error.bash
./error.bash: line 9: /var/tmp//sh-np-4223088879: Interrupted system call
./error.bash: line 9: /var/tmp//sh-np-638574683: Interrupted system call
./error.bash: line 9: /var/tmp//sh-np-3418944767: Interrupted system call
./error.bash: line 9: /var/tmp//sh-np-57321729: Interrupted system call

It seems that the number of "Interrupted system call"-outputs are
approximately half of the iterations in the for-loop, this holds true
with 5, 10, 20 and 30 iterations. Other than that it creates a lot of
/var/tmp/sh-np-* files and leaves -/usr/local/bin/bash-processes
running.

The system in question is a 7.0-Stable box with GNU bash, version
3.2.39(1)-release from ports. For the moment this problem does not
occur on my GNU/Linux Ubuntu 7.10-system. However, last time I tried
the script (some months ago) it did produce the same output as on the
FBSD-system.

More info, code and a runnable script is found on http://qwqb.com/error.bash

I am most thankful for any help or ideas you might give me. Thanks in advance!

Yours faithfully,
Tanel Rebane



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?e73893440807251535k8178035hc162e021e1d0da7c>