[DTrace-devel] [PATCH v2 2/4] runtest: detect coredumps in more cases

Kris Van Hees kris.van.hees at oracle.com
Fri Nov 15 04:51:11 UTC 2024


On Thu, Nov 14, 2024 at 10:01:06PM +0000, Nick Alcock via DTrace-devel wrote:
> Exitcode 139 == signal 11 == a coredump that should be reported as such,
> even if we can't find a core file anywhere.
> 
> Signed-off-by: Nick Alcock <nick.alcock at oracle.com>

Reviewed-by: Kris Van Hees <kris.van.hees at oracle.com>

> ---
>  runtest.sh | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/runtest.sh b/runtest.sh
> index 46b532d7e161f..94634f80c2ebf 100755
> --- a/runtest.sh
> +++ b/runtest.sh
> @@ -1361,9 +1361,9 @@ for dt in $dtrace; do
>                  want_all_output=t
>              fi
>  
> -            if [[ -f core ]] || [[ "$(find $tmpdir -name core -print)" != "" ]]; then
> +            if [[ -f core ]] || [[ "$(find $tmpdir -name core -print)" != "" ]] || [[ $exitcode = 139 ]]; then
>                  # A coredump in the current directory or under the tmpdir.
> -                # Preserve it in the logdir.
> +                # Preserve it in the logdir, if possible.
>  
>                  mv core $logdir/$(echo $base | tr '/' '-').core 2>/dev/null || true
>                  find $tmpdir -name core -type f -print0 | xargs -0r -I'{}' mv --backup=numbered '{}' $logdir/$(echo $base | tr '/' '-').core
> -- 
> 2.46.0.278.g36e3a12567
> 
> 
> _______________________________________________
> DTrace-devel mailing list
> DTrace-devel at oss.oracle.com
> https://oss.oracle.com/mailman/listinfo/dtrace-devel



More information about the DTrace-devel mailing list