[Mono-devel-list] Possible bug when using System.IO.FileStream

Zoltan Varga vargaz at gmail.com
Tue Mar 15 11:51:40 EST 2005


  This is now tracked as:



On Tue, 15 Mar 2005 16:46:32 +0100, Peter Magnusson
<crippledcanary at gmail.com> wrote:
> Description:
> When I use a FileStream(string, FileMode, FileAccess, FileShare, int,
> bool) constructor I get an error like below.
> ** ERROR **: Thread 0x930 calling into managed code is not registered
> with the GC. On UNIX, this can be fixed by #include-ing <gc.h> before
> <pthread.h> in the file containing the thread creation code.
> I use mono and mcs from revision 41836
> I have run the same test on my Windows machine and there it's working
> as expected and creates a file called "log.txt" and writes into that
> file.
> I don't know if this is expected behaviour but I don't think so.
> Steps to reproduce:
> I have attached a test class that can be compliled with "mcs test.cs"
> and run with "mono test.exe".
> The class contains 2 methods that use FileStream, one that is working
> and one wich isn't. The faulty one is called WriteLines_Faulty.

More information about the Mono-devel-list mailing list