diff options
Diffstat (limited to 'meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch')
-rw-r--r-- | meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch b/meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch index f5483db825..cf5dd95d48 100644 --- a/meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch +++ b/meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch | |||
@@ -1,8 +1,8 @@ | |||
1 | From 62fdead139edb0f29b2f222efcb8f39be15b057e Mon Sep 17 00:00:00 2001 | 1 | From 42076483ed38d50400156cbb75d4c9b0180e6957 Mon Sep 17 00:00:00 2001 |
2 | From: Hongxu Jia <hongxu.jia@windriver.com> | 2 | From: Hongxu Jia <hongxu.jia@windriver.com> |
3 | Date: Mon, 30 Jul 2018 15:47:13 +0800 | 3 | Date: Mon, 30 Jul 2018 15:47:13 +0800 |
4 | Subject: [PATCH 2/4] pykickstart/parser.py: add lock for readKickstart and | 4 | Subject: [PATCH] pykickstart/parser.py: add lock for readKickstart and support |
5 | support https without certification | 5 | https without certification |
6 | 6 | ||
7 | - Add lock for readKickstart to fix race issue | 7 | - Add lock for readKickstart to fix race issue |
8 | 8 | ||
@@ -13,15 +13,18 @@ Signed-off-by: Wang Mingyu <wangmy@fujitsu.com> | |||
13 | --- | 13 | --- |
14 | Upstream-Status: Pending | 14 | Upstream-Status: Pending |
15 | 15 | ||
16 | Rebase to 3.62 | ||
17 | Signed-off-by: Mingli Yu <mingli.yu@windriver.com> | ||
18 | --- | ||
16 | pykickstart/load.py | 2 +- | 19 | pykickstart/load.py | 2 +- |
17 | pykickstart/parser.py | 18 ++++++++++++++++++ | 20 | pykickstart/parser.py | 18 ++++++++++++++++++ |
18 | 2 files changed, 19 insertions(+), 1 deletion(-) | 21 | 2 files changed, 19 insertions(+), 1 deletion(-) |
19 | 22 | ||
20 | diff --git a/pykickstart/load.py b/pykickstart/load.py | 23 | diff --git a/pykickstart/load.py b/pykickstart/load.py |
21 | index 8da8051..e856c8d 100644 | 24 | index 45d402a..6eeffde 100644 |
22 | --- a/pykickstart/load.py | 25 | --- a/pykickstart/load.py |
23 | +++ b/pykickstart/load.py | 26 | +++ b/pykickstart/load.py |
24 | @@ -32,7 +32,7 @@ log = logging.getLogger("anaconda.main") | 27 | @@ -28,7 +28,7 @@ from requests.exceptions import SSLError, RequestException |
25 | 28 | ||
26 | is_url = lambda location: '://' in location # RFC 3986 | 29 | is_url = lambda location: '://' in location # RFC 3986 |
27 | 30 | ||
@@ -31,10 +34,10 @@ index 8da8051..e856c8d 100644 | |||
31 | def load_to_str(location, user=None, passwd=None): | 34 | def load_to_str(location, user=None, passwd=None): |
32 | '''Load a destination URL or file into a string. | 35 | '''Load a destination URL or file into a string. |
33 | diff --git a/pykickstart/parser.py b/pykickstart/parser.py | 36 | diff --git a/pykickstart/parser.py b/pykickstart/parser.py |
34 | index b95ba90..a55a9a3 100644 | 37 | index 351dc1b..aef59ca 100644 |
35 | --- a/pykickstart/parser.py | 38 | --- a/pykickstart/parser.py |
36 | +++ b/pykickstart/parser.py | 39 | +++ b/pykickstart/parser.py |
37 | @@ -51,6 +51,20 @@ from pykickstart.i18n import _ | 40 | @@ -54,6 +54,20 @@ from pykickstart.i18n import _ |
38 | STATE_END = "end" | 41 | STATE_END = "end" |
39 | STATE_COMMANDS = "commands" | 42 | STATE_COMMANDS = "commands" |
40 | 43 | ||
@@ -55,7 +58,7 @@ index b95ba90..a55a9a3 100644 | |||
55 | def _preprocessStateMachine(lineIter): | 58 | def _preprocessStateMachine(lineIter): |
56 | l = None | 59 | l = None |
57 | lineno = 0 | 60 | lineno = 0 |
58 | @@ -791,6 +805,10 @@ class KickstartParser(object): | 61 | @@ -832,6 +846,10 @@ class KickstartParser(object): |
59 | self._stateMachine(i) | 62 | self._stateMachine(i) |
60 | 63 | ||
61 | def readKickstart(self, f, reset=True, username=None, password=None): | 64 | def readKickstart(self, f, reset=True, username=None, password=None): |