[PATCH][FWTS-TEST] Simple detection of segmentation faults

Keng-Yü Lin keng-yu.lin at canonical.com
Mon Jul 8 08:17:06 UTC 2013


On Tue, Jul 2, 2013 at 6:32 AM, Colin King <colin.king at canonical.com> wrote:
> From: Colin Ian King <colin.king at canonical.com>
>
> fwts tests should detect any segmentation faults in fwts or
> in the fwts child processes.
>
> Signed-off-by: Colin Ian King <colin.king at canonical.com>
> ---
>  test.sh | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/test.sh b/test.sh
> index 9d4a9ba..7682d3d 100755
> --- a/test.sh
> +++ b/test.sh
> @@ -25,7 +25,12 @@ do
>         do
>                 if [ -x $J ]; then
>                         echo "TEST: $I, subtest $J" >> $FAILURE_LOG
> +                       ulimit -c unlimited
> +                       rm -f core*
>                         bash $J
> +                       if [ -e core* ]; then
> +                               echo "FAILED: Segmentation fault."
> +                       fi
>                         #
>                         # We can check for 0 (pass) or non-zero (fail)
>                         #
> --
> 1.8.1.2
>

Acked-by: Keng-Yu Lin <kengyu at canonical.com>



More information about the fwts-devel mailing list