Skip to contentSkip to conversation

mountstats: fix python2.x support

PATCH In review Weston Andros Adamson 2 participants 2 messages Oct 17, 2013 – Oct 21, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mountstats: fix python2.x support

Commit b703eabe4c4bc5c2d5fd9a07b6b995d67ea7e77a converted mountstats to using python3's print() function, but this doesn't work in python2.x without importing the print function from __future__.

---
 tools/mountstats/mountstats.py | 2 ++
 1 file changed, 2 insertions(+)
tools/mountstats/mountstats.py +2 -0
index 3f5fea5..e46105d 100644
@@ -3,6 +3,8 @@
 """Parse /proc/self/mountstats and display it in human readable form
 """
 
+from __future__ import print_function
+
 __copyright__ = """
 Copyright (C) 2005, Chuck Lever <[email protected]>
 
Signature · 1 line
1.7.12.4 (Apple Git-37)
#1 lore raw
Quoted 5 lines · Weston Andros Adamson

Commit b703eabe4c4bc5c2d5fd9a07b6b995d67ea7e77a converted mountstats to using python3's print() function, but this doesn't work in python2.x without importing the print function from __future__.

Committed...

steved.

Quoted 18 lines
---
 tools/mountstats/mountstats.py | 2 ++
 1 file changed, 2 insertions(+)
tools/mountstats/mountstats.py +2 -0
index 3f5fea5..e46105d 100644
@@ -3,6 +3,8 @@
 """Parse /proc/self/mountstats and display it in human readable form
 """
 
+from __future__ import print_function
+
 __copyright__ = """
 Copyright (C) 2005, Chuck Lever <[email protected]>