Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 Apr 2004 01:55:55 -0700 (PDT)
From:      Andrew Grillet <andrew@grillet.co.uk>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   misc/65843: poor handling of write protected floppy.
Message-ID:  <200404210855.i3L8tt9f011203@www.freebsd.org>
Resent-Message-ID: <200404210900.i3L90fNo027137@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         65843
>Category:       misc
>Synopsis:       poor handling of write protected floppy.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Apr 21 02:00:41 PDT 2004
>Closed-Date:
>Last-Modified:
>Originator:     Andrew Grillet
>Release:        4.9 Stable
>Organization:
Quickstart Technology Ltd
>Environment:
FreeBSD dayton.grillet.home 4.9-STABLE FreeBSD                   4.9-STABLE #3: Sun Mar 28 21:09:07 BST 2004                       root@dayton.grillet.home:/usr/src/sys/compile/DAYTON  i386     
>Description:
Handling of write protected floppy disks is totally naff! You get no message when you mount (write protected the floppy.  If you attempt to write to it (cp file /floppy) you get "io error" - suggesting a defective medium, and not "Illegal attempt to write to protected medium" or "flip the write protect tab, you nitwit". The, if you attempt to unmount the floppy to fix the problem, you are unable to do so, because the floppy is write-protected
>How-To-Repeat:
1) Instert write protected (but known good) floppy      
2) mount /floppy
3) cp file /floppy <confusing error here>
4) umount /floppy <inappropriate error here>
5) have attack of "floppy rage"
>Fix:
1) only allow ro mount if disk is write protected, otherwise refuse to mount.
2) detect the error code for "attempted write while write protected" and handle with more user friendly message      

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200404210855.i3L8tt9f011203>