libmount: add MNT_ERR_LOOPDEV
Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
parent
3fc480b952
commit
82756a747e
|
@ -173,6 +173,8 @@ int loopcxt_init(struct loopdev_cxt *lc, int flags)
|
|||
*/
|
||||
void loopcxt_deinit(struct loopdev_cxt *lc)
|
||||
{
|
||||
int errsv = errno;
|
||||
|
||||
if (!lc)
|
||||
return;
|
||||
|
||||
|
@ -183,6 +185,8 @@ void loopcxt_deinit(struct loopdev_cxt *lc)
|
|||
|
||||
loopcxt_set_device(lc, NULL);
|
||||
loopcxt_deinit_iterator(lc);
|
||||
|
||||
errno = errsv;
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -261,6 +261,7 @@ int mnt_context_setup_loopdev(struct libmnt_context *cxt)
|
|||
|
||||
if (loopdev || rc != -EBUSY) {
|
||||
DBG(CXT, mnt_debug_h(cxt, "failed to setup device"));
|
||||
rc = -MNT_ERR_LOOPDEV;
|
||||
goto done;
|
||||
}
|
||||
DBG(CXT, mnt_debug_h(cxt, "loopdev stolen...trying again"));
|
||||
|
|
|
@ -126,6 +126,7 @@ enum {
|
|||
#define MNT_ERR_NOFSTAB 5000 /* not found required entry in fstab */
|
||||
#define MNT_ERR_NOFSTYPE 5001 /* failed to detect filesystem type */
|
||||
#define MNT_ERR_NOSOURCE 5002 /* required mount source undefined */
|
||||
#define MNT_ERR_LOOPDEV 5003 /* loopdev setup failed, errno set by libc */
|
||||
|
||||
/* init.c */
|
||||
extern void mnt_init_debug(int mask);
|
||||
|
|
Loading…
Reference in New Issue