Blame SOURCES/0002-Fix-path-regex-for-and.patch

ab26de
From 744da6cbfb69d7cca3f38a51be0de98e7fa585d9 Mon Sep 17 00:00:00 2001
ab26de
From: Andy Grover <agrover@redhat.com>
ab26de
Date: Tue, 30 May 2017 15:37:25 -0700
ab26de
Subject: [PATCH] Fix path regex for [ and ]
ab26de
ab26de
When dealing with ipv6, we now have paths consisting of square
ab26de
brackets. We need to add these characters to the path regex for
ab26de
them to match properly.
ab26de
ab26de
Signed-off-by: Andy Grover <agrover@redhat.com>
ab26de
---
ab26de
 configshell/shell.py | 2 +-
ab26de
 1 file changed, 1 insertion(+), 1 deletion(-)
ab26de
ab26de
diff --git a/configshell/shell.py b/configshell/shell.py
ab26de
index e029c76..3d0fce9 100644
ab26de
--- a/configshell/shell.py
ab26de
+++ b/configshell/shell.py
ab26de
@@ -126,7 +126,7 @@ class ConfigShell(object):
ab26de
         parameter = kparam | pparam
ab26de
         parameters = OneOrMore(parameter)
ab26de
         bookmark = Regex('@([A-Za-z0-9:_.]|-)+')
ab26de
-        pathstd = Regex('([A-Za-z0-9:_.]|-)*' + '/' + '([A-Za-z0-9:_./]|-)*') \
ab26de
+        pathstd = Regex('([A-Za-z0-9:_.\[\]]|-)*' + '/' + '([A-Za-z0-9:_.\[\]/]|-)*') \
ab26de
                 | '..' | '.'
ab26de
         path = locatedExpr(bookmark | pathstd | '*')('path')
ab26de
         parser = Optional(path) + Optional(command) + Optional(parameters)