summaryrefslogtreecommitdiffstats
path: root/package/refpolicy/0001-fix-regex-escape-sequence-error.patch
diff options
context:
space:
mode:
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>2017-12-01 21:56:44 +0100
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>2017-12-01 21:56:44 +0100
commit1c8dda3e435cfadaffe1f0cc062ad3c8ffbe84a7 (patch)
treedd26d5bc619271f8cccf0c9d7abdda9a1749d13f /package/refpolicy/0001-fix-regex-escape-sequence-error.patch
parent57dcad243e6daefefbe21109e1fc97272053a7a0 (diff)
parent787a31fed42f98a8e2e6a0bd2079376c861436f2 (diff)
downloadbuildroot-1c8dda3e435cfadaffe1f0cc062ad3c8ffbe84a7.tar.gz
buildroot-1c8dda3e435cfadaffe1f0cc062ad3c8ffbe84a7.zip
Merge branch 'next'
This merges the next branch accumulated during the 2017.11 release cycle back into the master branch. A few conflicts had to be resolved: - In the DEVELOPERS file, because Fabrice Fontaine was added as a developer for libupnp in master, and for libupnp18 in next. Resolution is simple: add him for both. - linux/Config.in, because we updated the 4.13.x release used by default in master, while we moved to 4.14 in next. Resolution: use 4.14. - package/libupnp/libupnp.hash: a hash for the license file was added in master, while the package was bumped into next. Resolution: keep the hash for the license file, and keep the hash for the newest version of libupnp. - package/linux-headers/Config.in.host: default version of the kernel headers for 4.13 was bumped to the latest 4.13.x in master, but was changed to 4.14 in next. Resolution: use 4.14. - package/samba4/: samba was bumped to 4.6.11 in master for security reasons, but was bumped to 4.7.3 in next. Resolution: keep 4.7.3. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'package/refpolicy/0001-fix-regex-escape-sequence-error.patch')
-rw-r--r--package/refpolicy/0001-fix-regex-escape-sequence-error.patch59
1 files changed, 59 insertions, 0 deletions
diff --git a/package/refpolicy/0001-fix-regex-escape-sequence-error.patch b/package/refpolicy/0001-fix-regex-escape-sequence-error.patch
new file mode 100644
index 0000000000..1aa01892d0
--- /dev/null
+++ b/package/refpolicy/0001-fix-regex-escape-sequence-error.patch
@@ -0,0 +1,59 @@
+From 6c9cc47e6cc9c6e67b1b822f7a1a2e1f6d836118 Mon Sep 17 00:00:00 2001
+From: Adam Duskett <Adamduskett@outlook.com>
+Date: Tue, 10 Oct 2017 18:00:30 -0400
+Subject: [PATCH] fix regex escape sequence error.
+
+python3.6 will error out with the message "invalid escape sequence"
+in genhomedircon.py. This patch fixes these errors by turning the string
+in the into a raw string.
+
+Upstream status: accepted
+
+Signed-off-by: Adam Duskett <aduskett@gmail.com>
+---
+ support/genhomedircon.py | 16 ++++++++--------
+ 1 file changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/support/genhomedircon.py b/support/genhomedircon.py
+index 036f5cc9..6662f412 100644
+--- a/support/genhomedircon.py
++++ b/support/genhomedircon.py
+@@ -189,13 +189,13 @@ def oldgenhomedircon(filecontextdir, filecontext):
+ addme = 1
+ for regex in prefix_regex:
+ #match a trailing (/*)? which is actually a bug in rpc_pipefs
+- regex = re.sub("\(/\*\)\?$", "", regex)
++ regex = re.sub(r"\(/\*\)\?$", "", regex)
+ #match a trailing .+
+- regex = re.sub("\.+$", "", regex)
++ regex = re.sub(r"\.+$", "", regex)
+ #match a trailing .*
+- regex = re.sub("\.\*$", "", regex)
++ regex = re.sub(r"\.\*$", "", regex)
+ #strip a (/.*)? which matches anything trailing to a /*$ which matches trailing /'s
+- regex = re.sub("\(\/\.\*\)\?", "", regex)
++ regex = re.sub(r"\(\/\.\*\)\?", "", regex)
+ regex = regex + "/*$"
+ if re.search(regex, potential, 0):
+ addme = 0
+@@ -391,13 +391,13 @@ class selinuxConfig:
+ exists=1
+ for regex in prefix_regex:
+ #match a trailing (/*)? which is actually a bug in rpc_pipefs
+- regex = re.sub("\(/\*\)\?$", "", regex)
++ regex = re.sub(r"\(/\*\)\?$", "", regex)
+ #match a trailing .+
+- regex = re.sub("\.+$", "", regex)
++ regex = re.sub(r"\.+$", "", regex)
+ #match a trailing .*
+- regex = re.sub("\.\*$", "", regex)
++ regex = re.sub(r"\.\*$", "", regex)
+ #strip a (/.*)? which matches anything trailing to a /*$ which matches trailing /'s
+- regex = re.sub("\(\/\.\*\)\?", "", regex)
++ regex = re.sub(r"\(\/\.\*\)\?", "", regex)
+ regex = regex + "/*$"
+ if re.search(regex, home, 0):
+ exists = 0
+--
+2.13.6
+
OpenPOWER on IntegriCloud