Both programs give me the same output on mono 0.24 C:\DOCUME~1\joeri\MIJNDO~1\SHARPD~1\HELLOW~1>fin2 Constructor Bye! Destructor Free unmanaged resources.
C:\DOCUME~1\joeri\MIJNDO~1\SHARPD~1\HELLOW~1>fin Constructor Bye! Destructor Free unmanaged resources. ----- Original Message ----- From: "Giuseppe Greco" <[EMAIL PROTECTED]> To: "Joeri Belis" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Tuesday, July 22, 2003 7:44 PM Subject: Re: [Mono-list] Dispose method is never called > > >-- Original Message -- > >From: "Joeri Belis" <[EMAIL PROTECTED]> > >To: <[EMAIL PROTECTED]> > >Subject: Re: [Mono-list] Dispose method is never called > >Date: Tue, 22 Jul 2003 11:54:08 +0200 > > > > > >It compiled and ran the "MyFinalizer()" example with and without lines ( > >13 -> 15 ) > >but is get the same output results. Is this what to expect? > > > >C:\DOCUME~1\joeri\MIJNDO~1\SHARPD~1\HELLOW~1>fin.exe > >Constructor > >Bye! > >Destructor > >Free unmanaged resources. > > Yes, but when I run the example, I don't get the last two > messages... > > Have you commented out lines 13, 14, and 15? > > Gius_. > > > >> > >> Gonzalo, in mono-threaded applications the destructor > >> (or Finalize method) is called, but in multi-threaded > >> ones it isn't. Please try the attached program. As you > >> will see, the thread method is brutally interrupted and > >> the finalizer is never called. > >> > >> If you comment out line 13, 14, and 15 in finalizer.cs, > >> then it works fine. > >> > >> I hope that helps... > >> > >> Gius_. > >> > > > > > >_______________________________________________ > >Mono-list maillist - [EMAIL PROTECTED] > >http://lists.ximian.com/mailman/listinfo/mono-list > > > >
fin.cs
Description: Binary data
fin2.cs
Description: Binary data
