conf: cleanup macros lxc_chroot

parent 003be47b
......@@ -1349,7 +1349,6 @@ int lxc_chroot(const struct lxc_rootfs *rootfs)
int i, ret;
char *p, *p2;
char buf[LXC_LINELEN];
FILE *f;
char *root = rootfs->mount;
nroot = realpath(root, NULL);
......@@ -1388,6 +1387,7 @@ int lxc_chroot(const struct lxc_rootfs *rootfs)
* inherited mounts are locked and we should live with all this trash.
*/
for (;;) {
__do_fclose FILE *f = NULL;
int progress = 0;
f = fopen("./proc/self/mountinfo", "r");
......@@ -1421,8 +1421,6 @@ int lxc_chroot(const struct lxc_rootfs *rootfs)
progress++;
}
fclose(f);
if (!progress)
break;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment