WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] Removed unused getLevel method, and don't use intermedia

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Removed unused getLevel method, and don't use intermediate variable called
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 21 Sep 2005 14:58:15 +0000
Delivery-date: Wed, 21 Sep 2005 14:57:34 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User emellor@ewan
# Node ID 2eee9f6487ffa6cafe80484ad873e85064eff210
# Parent  79f695037ab7912b0e8690bff3e64a264f8d323d
Removed unused getLevel method, and don't use intermediate variable called
'log', as this name hides the global logger instance.

Signed-off-by: Ewan Mellor <ewan@xxxxxxxxxxxxx>

diff -r 79f695037ab7 -r 2eee9f6487ff tools/python/xen/xend/XendLogging.py
--- a/tools/python/xen/xend/XendLogging.py      Wed Sep 21 10:29:23 2005
+++ b/tools/python/xen/xend/XendLogging.py      Wed Sep 21 10:30:59 2005
@@ -50,9 +50,6 @@
         self.getLogger().setLevel(level)
         self.level = level
 
-    def getLevel(self, level):
-        return logging.getLevelName(self.level)
-
     def getLogger(self):
         return logging.getLogger("xend")
 
@@ -65,8 +62,7 @@
                                            backupCount=self.backupCount)
         self.logfilename = filename
         self.logfile.setFormatter(Formatter(self.logFileFormat, 
self.dateFormat))
-        log = self.getLogger()
-        log.addHandler(self.logfile)
+        self.getLogger().addHandler(self.logfile)
 
     def getLogFile(self):
         return self.logfile

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Removed unused getLevel method, and don't use intermediate variable called, Xen patchbot -unstable <=