On Wed, 2010-12-01 at 00:09 +0100, Magnus Fromreide wrote:
> On Tue, 2010-11-30 at 14:58 -0800, Wes Hardaker wrote:
> > >>>>> On Tue, 30 Nov 2010 23:26:00 +0100, Magnus Fromreide
> > >>>>> <[email protected]> said:
> >
> > MF> Is this (old broken shells) a big enough problem that we should fix
> > MF> it?
> >
> > Probably. It's not a hard fix. I assume that:
> >
> > if cmd ; then
> > :
> > else
> > stuff
> > fi
> >
> > works?
>
> Yes, it does.
Is this patch OK for 5.6 or am I to late?
Impact is only in the test scripts.
If a consensus is reached to apply it then I would like to ask someone
else to apply the patch as I might be connectivitywise challenged for a
while.
/MF
Index: trunk/net-snmp/testing/fulltests/default/T200snmpv2cwalkall_simple
===================================================================
--- trunk/net-snmp/testing/fulltests/default/T200snmpv2cwalkall_simple (revision 19734)
+++ trunk/net-snmp/testing/fulltests/default/T200snmpv2cwalkall_simple (working copy)
@@ -31,9 +31,7 @@
STARTAGENT
CAPTURE "$SNMPWALK $SNMP_FLAGS -$snmp_version -c testcommunity -t $TIMEOUT -r $RETRY $SNMP_TRANSPORT_SPEC:$SNMP_TEST_DEST$SNMP_SNMPD_PORT .1"
-if ! ISDEFINED USING_WINEXTDLL_MODULE; then
- CHECKANDDIE "= Wrong Type (should be "
-fi
+ISDEFINED USING_WINEXTDLL_MODULE || CHECKANDDIE "= Wrong Type (should be "
CHECKORDIE "No more variables left in this MIB View"
STOPAGENT
Index: trunk/net-snmp/testing/fulltests/support/simple_eval_tools.sh
===================================================================
--- trunk/net-snmp/testing/fulltests/support/simple_eval_tools.sh (revision 19734)
+++ trunk/net-snmp/testing/fulltests/support/simple_eval_tools.sh (working copy)
@@ -118,15 +118,11 @@
}
SKIPIFNOT() {
- if ! ISDEFINED "$1"; then
- SKIP "$1 is not defined"
- fi
+ ISDEFINED "$1" || SKIP "$1 is not defined"
}
SKIPIF() {
- if ISDEFINED "$1"; then
- SKIP "$1 is defined"
- fi
+ ISDEFINED "$1" && SKIP "$1 is defined"
}
#------------------------------------ -o-
Index: trunk/net-snmp/testing/fulltests/support/simple_run
===================================================================
--- trunk/net-snmp/testing/fulltests/support/simple_run (revision 19734)
+++ trunk/net-snmp/testing/fulltests/support/simple_run (working copy)
@@ -8,7 +8,9 @@
if [ "x$builddir" = "x" ]; then
cd ..
builddir=`pwd`
- if ! cd testing 2>/dev/null; then
+ if cd testing 2>/dev/null; then
+ :
+ else
echo "Error: $0 must be started from inside the testing directory."
exit 1
fi
@@ -17,7 +19,9 @@
if [ "x$srcdir" = "x" ]; then
cd ..
srcdir=`pwd`
- if ! cd testing 2>/dev/null; then
+ if cd testing 2>/dev/null; then
+ :
+ else
echo "Error: $0 must be started from inside the testing directory."
exit 1
fi
Index: branches/V5-4-patches/net-snmp/testing/eval_tools.sh
===================================================================
--- branches/V5-4-patches/net-snmp/testing/eval_tools.sh (revision 19734)
+++ branches/V5-4-patches/net-snmp/testing/eval_tools.sh (working copy)
@@ -116,15 +116,11 @@
}
SKIPIFNOT() {
- if ! ISDEFINED "$1"; then
- SKIP
- fi
+ ISDEFINED "$1" || SKIP
}
SKIPIF() {
- if ISDEFINED "$1"; then
- SKIP
- fi
+ ISDEFINED "$1" && SKIP
}
Index: branches/V5-4-patches/net-snmp/testing/tests/T200snmpv2cwalkall
===================================================================
--- branches/V5-4-patches/net-snmp/testing/tests/T200snmpv2cwalkall (revision 19734)
+++ branches/V5-4-patches/net-snmp/testing/tests/T200snmpv2cwalkall (working copy)
@@ -31,9 +31,7 @@
STARTAGENT
CAPTURE "$SNMPWALK $SNMP_FLAGS -$snmp_version -c testcommunity -t $TIMEOUT -r $RETRY $SNMP_TRANSPORT_SPEC:$SNMP_TEST_DEST$SNMP_SNMPD_PORT .1"
-if ! ISDEFINED USING_WINEXTDLL_MODULE; then
- CHECKANDDIE "= Wrong Type (should be "
-fi
+ISDEFINED USING_WINEXTDLL_MODULE || CHECKANDDIE "= Wrong Type (should be "
CHECKORDIE "No more variables left in this MIB View"
STOPAGENT
Index: branches/V5-5-patches/testing/eval_tools.sh
===================================================================
--- branches/V5-5-patches/testing/eval_tools.sh (revision 19734)
+++ branches/V5-5-patches/testing/eval_tools.sh (working copy)
@@ -116,15 +116,11 @@
}
SKIPIFNOT() {
- if ! ISDEFINED "$1"; then
- SKIP
- fi
+ ISDEFINED "$1" || SKIP
}
SKIPIF() {
- if ISDEFINED "$1"; then
- SKIP
- fi
+ ISDEFINED "$1" && SKIP
}
Index: branches/V5-5-patches/testing/tests/T200snmpv2cwalkall
===================================================================
--- branches/V5-5-patches/testing/tests/T200snmpv2cwalkall (revision 19734)
+++ branches/V5-5-patches/testing/tests/T200snmpv2cwalkall (working copy)
@@ -31,9 +31,7 @@
STARTAGENT
CAPTURE "$SNMPWALK $SNMP_FLAGS -$snmp_version -c testcommunity -t $TIMEOUT -r $RETRY $SNMP_TRANSPORT_SPEC:$SNMP_TEST_DEST$SNMP_SNMPD_PORT .1"
-if ! ISDEFINED USING_WINEXTDLL_MODULE; then
- CHECKANDDIE "= Wrong Type (should be "
-fi
+ISDEFINED USING_WINEXTDLL_MODULE || CHECKANDDIE "= Wrong Type (should be "
CHECKORDIE "No more variables left in this MIB View"
STOPAGENT
Index: branches/V5-6-patches/net-snmp/testing/fulltests/default/T200snmpv2cwalkall_simple
===================================================================
--- branches/V5-6-patches/net-snmp/testing/fulltests/default/T200snmpv2cwalkall_simple (revision 19734)
+++ branches/V5-6-patches/net-snmp/testing/fulltests/default/T200snmpv2cwalkall_simple (working copy)
@@ -31,9 +31,7 @@
STARTAGENT
CAPTURE "$SNMPWALK $SNMP_FLAGS -$snmp_version -c testcommunity -t $TIMEOUT -r $RETRY $SNMP_TRANSPORT_SPEC:$SNMP_TEST_DEST$SNMP_SNMPD_PORT .1"
-if ! ISDEFINED USING_WINEXTDLL_MODULE; then
- CHECKANDDIE "= Wrong Type (should be "
-fi
+ISDEFINED USING_WINEXTDLL_MODULE || CHECKANDDIE "= Wrong Type (should be "
CHECKORDIE "No more variables left in this MIB View"
STOPAGENT
Index: branches/V5-6-patches/net-snmp/testing/fulltests/support/simple_eval_tools.sh
===================================================================
--- branches/V5-6-patches/net-snmp/testing/fulltests/support/simple_eval_tools.sh (revision 19734)
+++ branches/V5-6-patches/net-snmp/testing/fulltests/support/simple_eval_tools.sh (working copy)
@@ -118,15 +118,11 @@
}
SKIPIFNOT() {
- if ! ISDEFINED "$1"; then
- SKIP "$1 is not defined"
- fi
+ ISDEFINED "$1" || SKIP "$1 is not defined"
}
SKIPIF() {
- if ISDEFINED "$1"; then
- SKIP "$1 is defined"
- fi
+ ISDEFINED "$1" && SKIP "$1 is defined"
}
#------------------------------------ -o-
Index: branches/V5-6-patches/net-snmp/testing/fulltests/support/simple_run
===================================================================
--- branches/V5-6-patches/net-snmp/testing/fulltests/support/simple_run (revision 19734)
+++ branches/V5-6-patches/net-snmp/testing/fulltests/support/simple_run (working copy)
@@ -8,7 +8,9 @@
if [ "x$builddir" = "x" ]; then
cd ..
builddir=`pwd`
- if ! cd testing 2>/dev/null; then
+ if cd testing 2>/dev/null; then
+ :
+ else
echo "Error: $0 must be started from inside the testing directory."
exit 1
fi
@@ -17,7 +19,9 @@
if [ "x$srcdir" = "x" ]; then
cd ..
srcdir=`pwd`
- if ! cd testing 2>/dev/null; then
+ if cd testing 2>/dev/null; then
+ :
+ else
echo "Error: $0 must be started from inside the testing directory."
exit 1
fi
------------------------------------------------------------------------------
Lotusphere 2011
Register now for Lotusphere 2011 and learn how
to connect the dots, take your collaborative environment
to the next level, and enter the era of Social Business.
http://p.sf.net/sfu/lotusphere-d2d
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders