From 6fc4c0ae3f80e6faf40f943dcfa58e2f8c7ee49a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= Date: Wed, 16 Apr 2014 17:00:25 +0200 Subject: [PATCH] appmenus: allow '_' in filenames --- appmenus-scripts/qubes-receive-appmenus | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/appmenus-scripts/qubes-receive-appmenus b/appmenus-scripts/qubes-receive-appmenus index 70931c9..3711380 100755 --- a/appmenus-scripts/qubes-receive-appmenus +++ b/appmenus-scripts/qubes-receive-appmenus @@ -88,8 +88,8 @@ def get_appmenus(vm): row_no = 0 appmenus = {} - line_rx = re.compile(r"([a-zA-Z0-9.()-]+.desktop):([a-zA-Z0-9-]+(?:\[[a-zA-Z@_]+\])?)=(.*)") - ignore_rx = re.compile(r".*([a-zA-Z0-9.-]+.desktop):(#.*|\s+)$") + line_rx = re.compile(r"([a-zA-Z0-9.()-_]+.desktop):([a-zA-Z0-9-]+(?:\[[a-zA-Z@_]+\])?)=(.*)") + ignore_rx = re.compile(r".*([a-zA-Z0-9.-_]+.desktop):(#.*|\s+)$") for untrusted_line in untrusted_appmenulist: # Ignore blank lines and comments if len(untrusted_line) == 0 or ignore_rx.match(untrusted_line):