mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-06 08:31:17 +00:00
i386/2427: 2.2-BETA ft driver panics when there're no floppy drives
Reviewed by: phk Submitted by: hosokawa@jp.FreeBSD.org
This commit is contained in:
parent
4fc96a56f5
commit
2a66b46b42
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=21455
|
@ -17,7 +17,7 @@
|
|||
* POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* ft.c - QIC-40/80 floppy tape driver
|
||||
* $Id: ft.c,v 1.27 1996/09/06 23:07:22 phk Exp $
|
||||
* $Id: ft.c,v 1.28 1996/11/27 22:51:46 phk Exp $
|
||||
*
|
||||
* 01/19/95 ++sg
|
||||
* Cleaned up recalibrate/seek code at attach time for FreeBSD 2.x.
|
||||
|
@ -2044,6 +2044,8 @@ ftopen(dev_t dev, int arg2) {
|
|||
/* check bounds */
|
||||
if (ftu >= NFT)
|
||||
return(ENXIO);
|
||||
if (!ft_data[ftu])
|
||||
return(ENXIO);
|
||||
fdc = ft_data[ftu]->fdc;
|
||||
if ((fdc == NULL) || (ft_data[ftu]->type == NO_TYPE))
|
||||
return(ENXIO);
|
||||
|
|
Loading…
Reference in a new issue