[Mono-bugs] [Bug 544357] Sponsoring an object in another appdomain does not appear to work

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed Oct 28 14:49:41 EDT 2009


http://bugzilla.novell.com/show_bug.cgi?id=544357

User lluis at novell.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=544357#c5


Lluis Sanchez <lluis at novell.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED




--- Comment #5 from Lluis Sanchez <lluis at novell.com>  2009-10-28 12:49:38 MDT ---
The problem been fixed in SVN (r144964). The fix has been backported to the 2.4
and 2.6 branches.

As a workaround for the problem, replace the call

ILease lease = (ILease)adder.InitializeLifetimeService();

by

ILease lease = (ILease)adder.GetLifetimeService();

Calling the method GetLifetimeService is more correct in this context because
the remoting infrastructure has already called InitializeLifetimeService to
create the lease of the object. In Mono, every call to
InitializeLifetimeService creates a new lease instance. So the sponsor was
being subscribed to a lease which wasn't really bound to the remote object. In
MS.NET, the second call will return the instance that has already been created.
The fix makes Mono behave like MS.NET.

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list