summaryrefslogtreecommitdiff
path: root/tests/touch/fifo
blob: 69c83bdb6aec4c6832d85bc1a186ecaa4e114da1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/bin/sh
# Make sure touch works on fifos without hanging.

if test "$VERBOSE" = yes; then
  set -x
  touch --version
fi

framework_failure=0

tmp=fifo-$$
rm -rf $tmp
mkfifo $tmp || framework_failure=1

if test $framework_failure = 1; then
  echo 'failure in testing framework'
  exit 1
fi

fail=0

touch $tmp || fail=1
rm -rf $tmp

exit $fail