Author: miguel
Date: 2005-07-08 16:26:42 -0400 (Fri, 08 Jul 2005)
New Revision: 47118
Modified:
branches/mono-1-1-7/mcs/class/corlib/System.IO/ChangeLog
branches/mono-1-1-7/mcs/class/corlib/System.IO/FileStream.cs
Log:
2005-05-16 Gonzalo Paniagua Javier <[EMAIL PROTECTED]>
* FileStream.cs: make WriteByte work in all cases when no buffer
is being used. Fixes bug #74971.
ue May 17 10:54:18 CEST 2005 Paolo Molaro <[EMAIL PROTECTED]>
* FileStream.cs: complete fix for #74971.
Modified: branches/mono-1-1-7/mcs/class/corlib/System.IO/ChangeLog
===================================================================
--- branches/mono-1-1-7/mcs/class/corlib/System.IO/ChangeLog 2005-07-08
20:25:29 UTC (rev 47117)
+++ branches/mono-1-1-7/mcs/class/corlib/System.IO/ChangeLog 2005-07-08
20:26:42 UTC (rev 47118)
@@ -1,3 +1,12 @@
+2005-05-16 Gonzalo Paniagua Javier <[EMAIL PROTECTED]>
+
+ * FileStream.cs: make WriteByte work in all cases when no buffer
+ is being used. Fixes bug #74971.
+
+ue May 17 10:54:18 CEST 2005 Paolo Molaro <[EMAIL PROTECTED]>
+
+ * FileStream.cs: complete fix for #74971.
+
2005-04-21 Gonzalo Paniagua Javier <[EMAIL PROTECTED]>
* UnexceptionalStreamWriter.cs: don't throw anything on Flush. Closes
Modified: branches/mono-1-1-7/mcs/class/corlib/System.IO/FileStream.cs
===================================================================
--- branches/mono-1-1-7/mcs/class/corlib/System.IO/FileStream.cs
2005-07-08 20:25:29 UTC (rev 47117)
+++ branches/mono-1-1-7/mcs/class/corlib/System.IO/FileStream.cs
2005-07-08 20:26:42 UTC (rev 47118)
@@ -374,6 +374,14 @@
if (buf_offset == buf_size)
FlushBuffer ();
+ if (buf_size == 0) { // No buffering
+ buf [0] = value;
+ buf_dirty = true;
+ buf_length = 1;
+ FlushBuffer ();
+ return;
+ }
+
buf [buf_offset ++] = value;
if (buf_offset > buf_length)
buf_length = buf_offset;
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches