[mono-android] Simple project with massive memory leak

Agustin Gimenez geniwab at gmail.com
Sun Nov 27 00:47:59 EST 2011


I agree that the threadpool calls are superfluous, calling directly to the
async methods would be the correct thing, but that had to not influence on
memory leakage inside a webclient.

As i said WebClient inherently leaks meory (at least in the fw 2.0, since
then I only used HttWebRequests because that), on MSDN where a little
advicement about cancelling async calls to a WebClient may derive in a
memory leakage, but it really happens without calling the cancelling
functions.

2011/11/27 Sayed Arian Kooshesh <kooshesh at gmail.com>

> maybe you guys should read up on garbage collection, references, and
> scope and see why his code is crap.
>
> queueworkeritem does not have anything to do with async calls. STop
> freekin using it.
>
>
> I mean, it's like asking why your cake is burned when you keep setting
> the oven to 500. If you can't see it after all my yelling well. Too
> bad.
>
> On Sat, Nov 26, 2011 at 11:38 PM, Sayed Arian Kooshesh
> <kooshesh at gmail.com> wrote:
> > gusman,
> > way to repeat everything i just said.
> >
> > On Sat, Nov 26, 2011 at 10:43 PM, Gusman <Geniwab at gmail.com> wrote:
> >> Sayed, you are helping no one.
> >>
> >> John is triying to know if the webclient leaks memory, so he wrote a
> cyclic
> >> app which calls DownloadString recursively to test those leakages.
> >>
> >> John, my experience, at least on Windows is that the webclient leaks
> memory
> >> with async calls.
> >> Using workerthreads is only a workaround to use synchronous calls, not a
> >> good idea(less performance and higher resource usage).
> >>
> >> You are creating anonymous delegates and a new webclient on each call,
> have
> >> you tried to reuse your items?
> >>
> >> My advine is to use a HttpWenRequest and use Its async methods.
> >>
> >> --
> >> View this message in context:
> http://mono-for-android.1047100.n5.nabble.com/Simple-project-with-massive-memory-leak-tp5011249p5025925.html
> >> Sent from the Mono for Android mailing list archive at Nabble.com.
> >> _______________________________________________
> >> Monodroid mailing list
> >> Monodroid at lists.ximian.com
> >>
> >> UNSUBSCRIBE INFORMATION:
> >> http://lists.ximian.com/mailman/listinfo/monodroid
> >>
> >
> >
> >
> > --
> > Extreme Knowledge is not something for which he programs a computer
> > but for which his computer is programming him.
> >
> > -Wozniak
> >
>
>
>
> --
> Extreme Knowledge is not something for which he programs a computer
> but for which his computer is programming him.
>
> -Wozniak
> _______________________________________________
> Monodroid mailing list
> Monodroid at lists.ximian.com
>
> UNSUBSCRIBE INFORMATION:
> http://lists.ximian.com/mailman/listinfo/monodroid
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/monodroid/attachments/20111127/81641e94/attachment.html 


More information about the Monodroid mailing list