diff options
author | Bogdan Purcareata <bogdan.purcareata@freescale.com> | 2013-05-16 12:09:57 +0300 |
---|---|---|
committer | Bruce Ashfield <bruce.ashfield@windriver.com> | 2013-05-17 09:47:19 -0700 |
commit | 1cbe97b642b44df5e60fb422164bd9773401db02 (patch) | |
tree | bafff06bc2673c70dfed2ca66c048bbc1c4f38b8 /recipes-containers/lxc/files | |
parent | 573186afdc36cf75849c6d8c17ab3ccd8b0668b3 (diff) | |
download | meta-virtualization-1cbe97b642b44df5e60fb422164bd9773401db02.tar.gz |
lxc-clone: don't let LXC_PATH end in failure
This patch has been included in the upstream repo as the first
patch after LXC 0.9.0 release. Including it in meta-virtualization
for proper functioning of the lxc-clone command.
Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Diffstat (limited to 'recipes-containers/lxc/files')
-rw-r--r-- | recipes-containers/lxc/files/lxc-0.9.0-don-t-let-LXC_PATH-end-in-failure.patch | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/recipes-containers/lxc/files/lxc-0.9.0-don-t-let-LXC_PATH-end-in-failure.patch b/recipes-containers/lxc/files/lxc-0.9.0-don-t-let-LXC_PATH-end-in-failure.patch new file mode 100644 index 00000000..fe9f8cc5 --- /dev/null +++ b/recipes-containers/lxc/files/lxc-0.9.0-don-t-let-LXC_PATH-end-in-failure.patch | |||
@@ -0,0 +1,29 @@ | |||
1 | From fd95f2402dc70ad41fa2db8fb101f950196458a9 Mon Sep 17 00:00:00 2001 | ||
2 | From: Serge Hallyn <serge.hallyn@ubuntu.com> | ||
3 | Date: Tue, 9 Apr 2013 16:23:05 -0500 | ||
4 | Subject: [PATCH] lxc.functions: don't let LXC_PATH= line end in failure | ||
5 | |||
6 | Otherwise if called from dash with set -e, dash will exit. This | ||
7 | causes lxc-clone to fail. | ||
8 | |||
9 | Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com> | ||
10 | --- | ||
11 | src/lxc/lxc.functions.in | 2 +- | ||
12 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
13 | |||
14 | diff --git a/src/lxc/lxc.functions.in b/src/lxc/lxc.functions.in | ||
15 | index b41f9b8..aa5717d 100644 | ||
16 | --- a/src/lxc/lxc.functions.in | ||
17 | +++ b/src/lxc/lxc.functions.in | ||
18 | @@ -26,7 +26,7 @@ templatedir=@LXCTEMPLATEDIR@ | ||
19 | lxcinitdir=@LXCINITDIR@ | ||
20 | |||
21 | get_default_lxcpath() { | ||
22 | - LXC_PATH=$(grep -v "^#" "$globalconf" 2>/dev/null | grep "[ \t]*lxcpath[ \t]*=") | ||
23 | + LXC_PATH=$(grep -v "^#" "$globalconf" 2>/dev/null | grep "[ \t]*lxcpath[ \t]*=") || true | ||
24 | if [ -n "$LXC_PATH" ]; then | ||
25 | echo $LXC_PATH | awk -F= '{ print $2 }' | ||
26 | else | ||
27 | -- | ||
28 | 1.7.11.7 | ||
29 | |||