From 8a8197ba7ac9310d7c574416d4249aaba9d02ea3e1475043631222f8a17834aa Mon Sep 17 00:00:00 2001 From: "Dr. Werner Fink" Date: Tue, 2 Mar 2010 16:43:52 +0000 Subject: [PATCH] . OBS-URL: https://build.opensuse.org/package/show/Base:System/bash?expand=0&rev=27 --- bash-4.1-intr.dif | 11 +++++++++++ run-tests | 14 ++++++++++++++ 2 files changed, 25 insertions(+) diff --git a/bash-4.1-intr.dif b/bash-4.1-intr.dif index 6affafc..c646a12 100644 --- a/bash-4.1-intr.dif +++ b/bash-4.1-intr.dif @@ -145,3 +145,14 @@ } #ifdef USING_BASH_MALLOC +--- builtins/read.def ++++ builtins/read.def 2010-03-02 16:24:59.070362886 +0000 +@@ -387,6 +387,8 @@ read_builtin (list) + input_string. We want to run all the rest and use input_string, + so we have to remove it from the stack. */ + remove_unwind_protect (); ++ interrupt_immediately--; ++ terminate_immediately = 0; + run_unwind_frame ("read_builtin"); + input_string[i] = '\0'; /* make sure it's terminated */ + retval = 128+SIGALRM; diff --git a/run-tests b/run-tests index 81e9543..c4a2510 100644 --- a/run-tests +++ b/run-tests @@ -26,4 +26,18 @@ do esac done +trap 'rm -f $tmp' EXIT TERM INT QUIT +tmp=$(mktemp /tmp/hello.XXXXXXXX) || exit 1 +echo '#!/bin/sh' > $tmp +echo exit >> $tmp +chmod 755 $tmp +${THIS_SH} -c $tmp + +typeset -i count=500 +echo '#########################' +echo 'fork + /bin/sh -c runtime' +time while ((count-- > 0)) ; do + ${THIS_SH} -c $tmp +done +echo '#########################' exit 0