← Back to team overview

cloud-init-dev team mailing list archive

[Merge] lp:~jason-oldos/cloud-init/bug-1338614 into lp:cloud-init

 

Jay Faulkner has proposed merging lp:~jason-oldos/cloud-init/bug-1338614 into lp:cloud-init.

Requested reviews:
  cloud init development team (cloud-init-dev)
Related bugs:
  Bug #1338614 in cloud-init: "Backgrounded resizing does not work"
  https://bugs.launchpad.net/cloud-init/+bug/1338614

For more details, see:
https://code.launchpad.net/~jason-oldos/cloud-init/bug-1338614/+merge/234749

Fixes https://bugs.launchpad.net/cloud-init/+bug/1338614
-- 
https://code.launchpad.net/~jason-oldos/cloud-init/bug-1338614/+merge/234749
Your team cloud init development team is requested to review the proposed merge of lp:~jason-oldos/cloud-init/bug-1338614 into lp:cloud-init.
=== modified file 'cloudinit/config/cc_resizefs.py'
--- cloudinit/config/cc_resizefs.py	2014-09-08 16:50:22 +0000
+++ cloudinit/config/cc_resizefs.py	2014-09-15 21:42:54 +0000
@@ -162,8 +162,8 @@
         # Fork to a child that will run
         # the resize command
         util.fork_cb(
-            util.log_time(logfunc=log.debug, msg="backgrounded Resizing",
-                func=do_resize, args=(resize_cmd, log)))
+            util.log_time, logfunc=log.debug, msg="backgrounded Resizing",
+            func=do_resize, args=(resize_cmd, log))
     else:
         util.log_time(logfunc=log.debug, msg="Resizing",
             func=do_resize, args=(resize_cmd, log))

=== modified file 'cloudinit/util.py'
--- cloudinit/util.py	2014-08-26 19:53:41 +0000
+++ cloudinit/util.py	2014-09-15 21:42:54 +0000
@@ -191,12 +191,17 @@
     return fh
 
 
-def fork_cb(child_cb, *args):
+def fork_cb(child_cb, *args, **kwargs):
     fid = os.fork()
     if fid == 0:
         try:
+<<<<<<< TREE
             child_cb(*args)
             os._exit(0)
+=======
+            child_cb(*args, **kwargs)
+            os._exit(0)  # pylint: disable=W0212
+>>>>>>> MERGE-SOURCE
         except:
             logexc(LOG, "Failed forking and calling callback %s",
                    type_utils.obj_name(child_cb))


Follow ups