lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20070926061926.GF2367@kernel.dk>
Date:	Wed, 26 Sep 2007 08:19:26 +0200
From:	Jens Axboe <jens.axboe@...cle.com>
To:	Al Viro <viro@....linux.org.uk>
Cc:	torvalds@...ux-foundation.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] cdrom_open() forgets to unlock on -EROFS failure exits

On Wed, Sep 26 2007, Al Viro wrote:
> 
> Signed-off-by: Al Viro <viro@...iv.linux.org.uk>
> ---
>  drivers/cdrom/cdrom.c |    4 ++++
>  1 files changed, 4 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/cdrom/cdrom.c b/drivers/cdrom/cdrom.c
> index 67ee3d4..7924571 100644
> --- a/drivers/cdrom/cdrom.c
> +++ b/drivers/cdrom/cdrom.c
> @@ -1032,6 +1032,10 @@ int cdrom_open(struct cdrom_device_info *cdi, struct inode *ip, struct file *fp)
>  	check_disk_change(ip->i_bdev);
>  	return 0;
>  err_release:
> +	if (CDROM_CAN(CDC_LOCK) && cdi->options & CDO_LOCK) {
> +		cdi->ops->lock_door(cdi, 0);
> +		cdinfo(CD_OPEN, "door unlocked.\n");
> +	}
>  	cdi->ops->release(cdi);
>  err:
>  	cdi->use_count--;
> -- 
> 1.5.3.GIT

Looks good Al, applied.

-- 
Jens Axboe

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ