]> git.ipfire.org Git - thirdparty/util-linux.git/commit
losetup: don't clear FD at EBUSY error in loopcxt_setup_device()
authorStanislav Brabec <sbrabec@suse.cz>
Tue, 27 May 2014 18:38:10 +0000 (20:38 +0200)
committerKarel Zak <kzak@redhat.com>
Wed, 28 May 2014 07:18:28 +0000 (09:18 +0200)
commitf7e21185087c30c5f13bf92009238e316f8c1cf4
treec8274bc7f0b83f52d3b468ee2ee63d8f00c6be9c
parentf37b357b47a4329f578722b193d4aa070057a04f
losetup: don't clear FD at EBUSY error in loopcxt_setup_device()

loopback lib clears the existing FD unconditionally at error in
loopcxt_setup_device().  This is done even after EBUSY, thus the second call
actually clears the previous setup wrongly.

Author:  Takashi Iwai <tiwai@suse.de>
Signed-off-by: Stanislav Brabec <sbrabec@suse.cz>
lib/loopdev.c