summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTzafrir Cohen <tzafrir@cohens.org.il>2011-11-23 21:45:37 +0200
committerTzafrir Cohen <tzafrir@cohens.org.il>2011-11-23 21:45:37 +0200
commita3a92bf97b14a0d04dd57bca6bb8e1674733b27d (patch)
tree2527c1ddba99b6deef4c2976c1f8fc86ef600d44
parent773e5fd8e193beb3dfc6a9f5a0e534e6d830aa6e (diff)
parse <support_level> and '<use type='
* Slightly better parsing of the XML data. * The attribute (type=FOO) is lost, though. Signed-off-by: Tzafrir Cohen <tzafrir@cohens.org.il>
-rwxr-xr-xmenuselect/menuselect2
1 files changed, 1 insertions, 1 deletions
diff --git a/menuselect/menuselect b/menuselect/menuselect
index 0530a8b..7e26a9c 100755
--- a/menuselect/menuselect
+++ b/menuselect/menuselect
@@ -111,7 +111,7 @@ sub warning($) {
# <var>value</var> --> Var: value
sub extract_xml_key($) {
my $xml_line = shift;
- if ($xml_line !~ m{^\s*<([a-zA-Z0-9]*)>([^<]*)</\1>}) {
+ if ($xml_line !~ m{^\s*<([a-z_A-Z0-9]+)(\s+([^>]*))?>([^<]*)</\1>}) {
warning "parsed empty value from XML line $xml_line";
return ('', ''); # warn?
}