[PATCH 02/39] xfs_buflock: handling parsing errors more gracefully

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

 



Skip ftrace output lines that don't parse.

Signed-off-by: Darrick J. Wong <darrick.wong@xxxxxxxxxx>
---
 tools/xfsbuflock.py |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)


diff --git a/tools/xfsbuflock.py b/tools/xfsbuflock.py
index f307461..82b6e01 100755
--- a/tools/xfsbuflock.py
+++ b/tools/xfsbuflock.py
@@ -150,7 +150,10 @@ for line in fileinput.input():
 	if len(toks) < 4:
 		continue
 	pid = toks[0]
-	time = float(toks[2][:-1])
+	try:
+		time = float(toks[2][:-1])
+	except:
+		continue
 	fn = toks[3][:-1]
 
 	if pid in processes:

--
To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux