[yakkety/master-next,2/2] UBUNTU: hv_set_ifconfig -- ensure we include the last stanza
diff mbox

Message ID 20161109102337.6005-3-apw@canonical.com
State New
Headers show

Commit Message

Andy Whitcroft Nov. 9, 2016, 10:23 a.m. UTC
BugLink: http://bugs.launchpad.net/bugs/1640109
Signed-off-by: Andy Whitcroft <apw@canonical.com>
---
 debian/cloud-tools/hv_set_ifconfig | 3 +++
 1 file changed, 3 insertions(+)

Comments

Colin King Nov. 9, 2016, 10:46 a.m. UTC | #1
On 09/11/16 10:23, Andy Whitcroft wrote:
> BugLink: http://bugs.launchpad.net/bugs/1640109
> Signed-off-by: Andy Whitcroft <apw@canonical.com>
> ---
>  debian/cloud-tools/hv_set_ifconfig | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/debian/cloud-tools/hv_set_ifconfig b/debian/cloud-tools/hv_set_ifconfig
> index 1ed7158..d8b0487 100755
> --- a/debian/cloud-tools/hv_set_ifconfig
> +++ b/debian/cloud-tools/hv_set_ifconfig
> @@ -239,6 +239,9 @@ for line in flines:
>                  newfile += [line.strip()]
>      prev_line=line
>  
> +# Include pending stanza if any.
> +if inastanza and not pitchstanza:
> +    newfile.extend(stanza)
>  
>  
>  def emit(line):
> 
Acked-by: Colin Ian King <colin.king@canonical.com>
Brad Figg Nov. 9, 2016, 1:52 p.m. UTC | #2
Looks reasonable

Patch
diff mbox

diff --git a/debian/cloud-tools/hv_set_ifconfig b/debian/cloud-tools/hv_set_ifconfig
index 1ed7158..d8b0487 100755
--- a/debian/cloud-tools/hv_set_ifconfig
+++ b/debian/cloud-tools/hv_set_ifconfig
@@ -239,6 +239,9 @@  for line in flines:
                 newfile += [line.strip()]
     prev_line=line
 
+# Include pending stanza if any.
+if inastanza and not pitchstanza:
+    newfile.extend(stanza)
 
 
 def emit(line):