summaryrefslogtreecommitdiff
path: root/qa/281
diff options
context:
space:
mode:
Diffstat (limited to 'qa/281')
-rwxr-xr-xqa/28145
1 files changed, 45 insertions, 0 deletions
diff --git a/qa/281 b/qa/281
new file mode 100755
index 0000000..4340a0e
--- /dev/null
+++ b/qa/281
@@ -0,0 +1,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