From 3a038b2df84eb5fe1ff73c450c29d71e95b586d3 Mon Sep 17 00:00:00 2001 From: "vinay.sajip" Date: Tue, 31 Oct 2006 17:32:37 +0000 Subject: [PATCH] Change to improve speed of _fixupChildren git-svn-id: http://svn.python.org/projects/python/trunk@52555 6015fed2-1504-0410-9fe1-9d1591cc4771 --- Lib/logging/__init__.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Lib/logging/__init__.py b/Lib/logging/__init__.py index 71efbd67fb..c72730843e 100644 --- a/Lib/logging/__init__.py +++ b/Lib/logging/__init__.py @@ -910,9 +910,12 @@ class Manager: Ensure that children of the placeholder ph are connected to the specified logger. """ - #for c in ph.loggers: + name = alogger.name + namelen = len(name) for c in ph.loggerMap.keys(): - if string.find(c.parent.name, alogger.name) <> 0: + #The if means ... if not c.parent.name.startswith(nm) + #if string.find(c.parent.name, nm) <> 0: + if c.parent.name[:namelen] != name: alogger.parent = c.parent c.parent = alogger -- 2.11.4.GIT