[PATCH blktests 01/15] common/rc: Fix _have_tracepoint()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Make sure that _have_tracepoint() uses the argument passed to that
function instead of using an undefined variable.

Signed-off-by: Bart Van Assche <bart.vanassche@xxxxxxx>
---
 common/rc | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/common/rc b/common/rc
index 7f1728025364..7592400dda82 100644
--- a/common/rc
+++ b/common/rc
@@ -112,6 +112,8 @@ _have_tracefs() {
 }
 
 _have_tracepoint() {
+	local event=$1
+
 	if [[ ! -d /sys/kernel/debug/tracing/events/${event} ]]; then
 		SKIP_REASON="tracepoint ${event} does not exist"
 		return 1
-- 
2.17.1




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux