public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH v2] route{4, 6}-rmmod: Declare variables before using them
@ 2020-09-10  2:30 Feiyu Zhu
  2020-09-10  8:54 ` Petr Vorel
  0 siblings, 1 reply; 2+ messages in thread
From: Feiyu Zhu @ 2020-09-10  2:30 UTC (permalink / raw)
  To: ltp

When running route4-rmmod case, it reports the following error:
/opt/ltp/testcases/bin/route4-rmmod: line 100: lhost_module: unbound variable.

It fails because "set -u" is used in .testcases/lib/cmdlib.sh and
"set -u" treats unset variables and parameters as errors.

Reviewed-by: Petr Vorel <pvorel@suse.cz>
Signed-off-by: Feiyu Zhu <zhufy.jy@cn.fujitsu.com>
---
 testcases/network/stress/route/route4-rmmod | 3 +++
 testcases/network/stress/route/route6-rmmod | 3 +++
 2 files changed, 6 insertions(+)

diff --git a/testcases/network/stress/route/route4-rmmod b/testcases/network/stress/route/route4-rmmod
index 5947bb3..7aa1958 100644
--- a/testcases/network/stress/route/route4-rmmod
+++ b/testcases/network/stress/route/route4-rmmod
@@ -125,6 +125,9 @@ do_setup()
 	exit $TST_TOTAL
     fi
 
+    # The module name of the interface at the local host
+    lhost_module=
+
     # Make sure to clean up
     do_cleanup
 
diff --git a/testcases/network/stress/route/route6-rmmod b/testcases/network/stress/route/route6-rmmod
index 73f26f2..765a57a 100644
--- a/testcases/network/stress/route/route6-rmmod
+++ b/testcases/network/stress/route/route6-rmmod
@@ -121,6 +121,9 @@ do_setup()
 	exit $TST_TOTAL
     fi
 
+    # The module name of the interface at the local host
+    lhost_module=
+
     # Make sure to clean up
     do_cleanup
 
-- 
1.8.3.1




^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [LTP] [PATCH v2] route{4, 6}-rmmod: Declare variables before using them
  2020-09-10  2:30 [LTP] [PATCH v2] route{4, 6}-rmmod: Declare variables before using them Feiyu Zhu
@ 2020-09-10  8:54 ` Petr Vorel
  0 siblings, 0 replies; 2+ messages in thread
From: Petr Vorel @ 2020-09-10  8:54 UTC (permalink / raw)
  To: ltp

Hi Feiyu,

> When running route4-rmmod case, it reports the following error:
> /opt/ltp/testcases/bin/route4-rmmod: line 100: lhost_module: unbound variable.

> It fails because "set -u" is used in .testcases/lib/cmdlib.sh and
> "set -u" treats unset variables and parameters as errors.

Thanks a lot for update, merged.

Kind regards,
Petr

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-09-10  8:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-09-10  2:30 [LTP] [PATCH v2] route{4, 6}-rmmod: Declare variables before using them Feiyu Zhu
2020-09-10  8:54 ` Petr Vorel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox