[Mono-bugs] [Bug 54521][Wis] New - Opening FileStreams from readonly files crashes

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Wed, 18 Feb 2004 08:09:17 -0500 (EST)

Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by tapia@eitig.com.


--- shadow/54521	2004-02-18 08:09:17.000000000 -0500
+++ shadow/54521.tmp.22493	2004-02-18 08:09:17.000000000 -0500
@@ -0,0 +1,34 @@
+Bug#: 54521
+Product: Mono/Class Libraries
+Version: unspecified
+OS Details: 
+Status: NEW   
+Priority: Wishlist
+Component: CORLIB
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: tapia@eitig.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+Summary: Opening FileStreams from readonly files crashes
+Description of Problem:
+Opening a FileStream this way:
+FileStream fs = new FileStream(path, FileMode.Open, FileAccess.Read);
+crashes if the file pointed by "path" is readonly (444, by example).
+Actual Results:
+Unhandled Exception: System.UnauthorizedAccessException: Access to the path
+"/home/tapia/file.txt" is denied.
+Expected Results:
+A readonly stream :-)