From ddf8e79a6a93d1db6bf3c30d8991e86836a11d69 Mon Sep 17 00:00:00 2001 Message-Id: From: Mark Wooding Date: Sun, 25 Dec 2011 23:58:43 +0000 Subject: [PATCH] extract-profile.in: Property name fixup wasn't applied to ${...} tokens. Organization: Straylight/Edgeware From: Mark Wooding Move it into the common replacement code. --- extract-profile.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/extract-profile.in b/extract-profile.in index c3a224b..dc816f3 100755 --- a/extract-profile.in +++ b/extract-profile.in @@ -279,7 +279,7 @@ class Section (object, UD.DictMixin): left = dol + 1 while left < n and (string[left].isalnum() or string[left] in '-_'): left += 1 - prop = string[dol + 1:left].replace('-', '_') + prop = string[dol + 1:left] ## If we came up empty, report an error. if prop == '': @@ -287,6 +287,7 @@ class Section (object, UD.DictMixin): "invalid placeholder (empty name) in `%s'" % string ## Extend the path: we're going to do a recursive expansion. + prop = prop.replace('-', '_') path.append(prop) ## Report a cycle if we found one. -- [mdw]