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

[Xen-changelog] [xen-unstable] Fix XendLogging to work on Python 2.4.0 and 2.4.1 (the logging library interface



# HG changeset patch
# User Ewan Mellor <ewan@xxxxxxxxxxxxx>
# Date 1170776231 0
# Node ID 39a2833dde5121b3e776a0ef2c6fcde4f23bd9f7
# Parent  0c17f16f9f0309c3ca452e3d35df006fccf96dea
Fix XendLogging to work on Python 2.4.0 and 2.4.1 (the logging library interface
changed with 2.4.2, not 2.4.0).

Signed-off-by: Qing He <qing.he@xxxxxxxxx>
---
 tools/python/xen/xend/XendLogging.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff -r 0c17f16f9f03 -r 39a2833dde51 tools/python/xen/xend/XendLogging.py
--- a/tools/python/xen/xend/XendLogging.py      Tue Feb 06 15:35:18 2007 +0000
+++ b/tools/python/xen/xend/XendLogging.py      Tue Feb 06 15:37:11 2007 +0000
@@ -52,8 +52,8 @@ if 'TRACE' not in logging.__dict__:
         for frame in frames:
             filename = os.path.normcase(frame[1])
             if filename != thisfile and filename != logging._srcfile:
-                major, minor, _, _, _ = sys.version_info
-                if major == 2 and minor >= 4:
+                major, minor, micro, _, _ = sys.version_info
+                if (major, minor, micro) >= (2, 4, 2):
                     return filename, frame[2], frame[3]
                 else:
                     return filename, frame[2]

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.