[Mono-bugs] [Bug 47404][Cri] Changed - System.IO.StreamReader's impl of buffers balks on non seeking streams

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
Tue, 5 Aug 2003 14:54:09 -0400 (EDT)


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 ginga@kit.hi-ho.ne.jp.

http://bugzilla.ximian.com/show_bug.cgi?id=47404

--- shadow/47404	Tue Aug  5 14:33:01 2003
+++ shadow/47404.tmp.31967	Tue Aug  5 14:54:09 2003
@@ -63,6 +63,13 @@
 http://cvs.hispalinux.es/cgi-bin/cvsweb/mcs/class/corlib/System.IO/StreamReader.cs.diff?r1=1.29&r2=1.30&cvsroot=mono
 
 ------- Additional Comments From ginga@kit.hi-ho.ne.jp  2003-08-05 14:33 -------
 Created an attachment (id=5066)
 This patch simply catches NotsupportedException and ignores it.
 
+
+------- Additional Comments From ginga@kit.hi-ho.ne.jp  2003-08-05 14:54 -------
+The above patch is not good at performance because of exception 
+handling. A bit better way is to try to cast Stream as FileStream 
+(hopefully once in the construction phase), and if it relly is, then 
+check CanSeek and skip this check.
+