blob: 4340a0e1af4260259b4297e8233a528af991e206 (
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
#! /bin/sh
# PCP QA Test No. 281
# Exercise pmNewContext() for archives close to the NOFILE max fd limit.
# For incident: 504616
#
# Copyright (c) 1995-2002 Silicon Graphics, Inc. All Rights Reserved.
#
seq=`basename $0`
echo "QA output created by $seq"
# get standard filters
. ./common.product
. ./common.filter
status=1 # failure is the default!
trap "cd; rm -rf $tmp; exit \$status" 0 1 2 3 15
rm -rf $tmp
mkdir $tmp
cp src/foo.* $tmp
# real QA test starts here
cd $tmp
$here/src/arch_maxfd foo \
| tee $seq.full \
| $PCP_AWK_PROG '
$1 == "max" { if (maxctx == "") maxctx = $NF
$NF = "<max>-" maxctx-$NF
}
{ print }'
if [ "`echo core*`" != "core*" ]
then
echo "$here/src/arch_maxfd dumped core!"
ls -l core*
unset TOOLROOT
echo where | dbx $here/src/arch_maxfd
exit
fi
# success, all done
status=0
exit
|