Quoting Veerendra ([EMAIL PROTECTED]):
>
> Signed-off-by: Veerendra C <[EMAIL PROTECTED]>
>
> This patch consists of the files..
>
> containers/container_test.sh
> containers/netns/runnetnstest.sh
>
>
>
> Regards
> Veerendra C
>
>
>
> --~--~---------~--~----~------------~-------~--~----~
> You received this message because you are subscribed to the Google Groups
> "lxc-dev" group.
> To post to this group, send email to [EMAIL PROTECTED]
> To unsubscribe from this group, send email to [EMAIL PROTECTED]
> For more options, visit this group at
> http://groups.google.com/group/lxc-dev?hl=en
> -~----------~----~----~----~------~----~------~--~---
>
> Index: containers/container_test.sh
> ===================================================================
> --- containers.orig/container_test.sh
> +++ containers/container_test.sh
> @@ -62,3 +62,10 @@ else
> echo "pid namespaces not enabled in kernel. Not running pidns tests."
> fi
>
> +check_netns_enabled
> +if [ $? -eq 0 ]; then
> + echo "Running netns tests."
> + runnetnstest.sh
> +else
> + echo "Net namespaces not enabled in kernel. Not running netns tests."
> +fi
> Index: containers/netns/runnetnstest.sh
> ===================================================================
> --- /dev/null
> +++ containers/netns/runnetnstest.sh
> @@ -0,0 +1,60 @@
> +##
> ##
> +## Copyright (c) International Business Machines Corp., 2007
> ##
> +##
> ##
> +## This program is free software; you can redistribute it and#or modify
> ##
> +## it under the terms of the GNU General Public License as published by
> ##
> +## the Free Software Foundation; either version 2 of the License, or
> ##
> +## (at your option) any later version.
> ##
> +##
> ##
> +## This program is distributed in the hope that it will be useful, but
> ##
> +## WITHOUT ANY WARRANTY; without even the implied warranty of
> MERCHANTABILITY ##
> +## or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
> ##
> +## for more details.
> ##
> +##
> ##
> +## You should have received a copy of the GNU General Public License
> ##
> +## along with this program; if not, write to the Free Software
> ##
> +## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
> ##
> +##
> ##
> +################################################################################
> +
> +#!/bin/sh
> +
> +exit_code=0
> +crtchild
> +if [ $? -ne 0 ]; then
> + exit_code="$?"
> + errmesg="crtchild $exit_code"
> +fi
> +
> +two_children_ns
> +if [ $? -ne 0 ]; then
> + exit_code="$?"
But I don't think this works. At this point, $? is 0.
You need to save away $? before testing it. i.e.
two_children_ns
x=$?
if [ $x -ne 0 ]; then
exit_code=$x
done
> + errmesg="$errmesg two_children_ns $exit_code "
> +fi
> +
> +crtchild_delchild
> +if [ $? -ne 0 ]; then
> + exit_code="$?"
> + errmesg='crtchild '
> + errmesg="$errmesg crtchild_delchild $exit_code "
> +fi
> +
> +netns_ftp
> +if [ $? -ne 0 ]; then
> + exit_code="$?"
> + errmesg="$errmesg netns_ftp $exit_code "
> +fi
> +
> +par_chld_ipv6
> +if [ $? -ne 0 ]; then
> + exit_code="$?"
> + errmesg="$errmesg par_chld_ipv6 $exit_code "
> +fi
> +
> +sysfsview
> +if [ $? -ne 0 ]; then
> + exit_code="$?"
> + errmesg="$errmesg sysfsview $exit_code "
> +fi
> +tst_resm TINFO $errmesg
> +exit $exit_code
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list