From e677dfedd1183da404e781a48607ad7a8a7e6d87 Mon Sep 17 00:00:00 2001 From: Mark Whitley Date: Mon, 26 Feb 2001 17:45:58 +0000 Subject: Applied patch from Magnus Damm to fix a 'inner scope var masking outer scope var with same name' bug that was preventing the loopback device from being unmounted if mount() fails. --- util-linux/mount.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'util-linux/mount.c') diff --git a/util-linux/mount.c b/util-linux/mount.c index 7b0bf3e21..551695b9b 100644 --- a/util-linux/mount.c +++ b/util-linux/mount.c @@ -128,7 +128,8 @@ do_mount(char *specialfile, char *dir, char *filesystemtype, #if defined BB_FEATURE_MOUNT_LOOP if (use_loop==TRUE) { int loro = flags & MS_RDONLY; - char *lofile = specialfile; + + lofile = specialfile; specialfile = find_unused_loop_device(); if (specialfile == NULL) { -- cgit v1.2.3