Re: {Spam?} Re: memory leak in gtk

2007-11-25 Thread Emmanuele Bassi

On Sat, 2007-11-24 at 10:09 +0100, Vincent Torri wrote:

> >> From what I've heard about memory leaking, this is not unique to the
> > GTK library.  If the rumours are correct, applications like `ls` are
> > notorious for leaking memory, safe in the knowledge that the OS will
> > clean up after them.
> 
> and if someone calls 'ls' iteratively in his program ?

if you call 'ls' in a child process the "leak" happens in you child
process, so it will be cleaned up by the OS when the child process
terminates and the parent reaps it. the memory will be reassigned to
other applications, thus is *not* a leak.

in a real leak the OS cannot reassign the leaked memory because your
application is still the owner.

ciao,
 Emmanuele.

-- 
Emmanuele Bassi,
W: http://www.emmanuelebassi.net
B: http://log.emmanuelebassi.net

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: {Spam?} Re: {Spam?} Re: memory leak in gtk

2007-11-24 Thread Junior Polegato - GTK+ & GTKmm
Vincent Torri escreveu:
> On Sat, 24 Nov 2007, Junior Polegato - GTK+ & GTKmm wrote:
>> Vincent Torri escreveu:
>>> On Sat, 24 Nov 2007, Michael Lamothe wrote:
> From what I've heard about memory leaking, this is not unique to the
 GTK library.  If the rumours are correct, applications like `ls` are
 notorious for leaking memory, safe in the knowledge that the OS will
 clean up after them.
>>> and if someone calls 'ls' iteratively in his program ?
>> When a process finish, the OS clean up memory. However, on some 
>> cases, the cost to freeing the memory is greater than let to the OS.
> and ? You have definitely a leak there. Calling, in your program (with 
> the exec() functions family), iteratively and infinitely a program 
> that leaks can crash your system. 'ls' is maybe not a good example, 
> but i'm sure you see what I mean ;)
I said "on some cases", like "ls". On this case you have described, the 
cost is the system crash.

-- 
Yours Truly,

   Junior Polegato

   A pilgrim of problems; A parchment of solutions!
   Professional Page: http://www.juniorpolegato.com.br

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: {Spam?} Re: {Spam?} Re: memory leak in gtk

2007-11-24 Thread Vincent Torri


On Sat, 24 Nov 2007, Junior Polegato - GTK+ & GTKmm wrote:

> Vincent Torri escreveu:
>> On Sat, 24 Nov 2007, Michael Lamothe wrote:
>> 
 From what I've heard about memory leaking, this is not unique to the
 
>>> GTK library.  If the rumours are correct, applications like `ls` are
>>> notorious for leaking memory, safe in the knowledge that the OS will
>>> clean up after them.
>>> 
>> and if someone calls 'ls' iteratively in his program ?
>> 
> When a process finish, the OS clean up memory. However, on some cases, the 
> cost to freeing the memory is greater than let to the OS.

and ? You have definitely a leak there. Calling, in your program (with 
the exec() functions family), iteratively and infinitely a program that 
leaks can crash your system. 'ls' is maybe not a good example, but i'm 
sure you see what I mean ;)

Vincent Torri
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: {Spam?} Re: memory leak in gtk

2007-11-24 Thread Junior Polegato - GTK+ & GTKmm
Vincent Torri escreveu:
> On Sat, 24 Nov 2007, Michael Lamothe wrote:
>   
>>> From what I've heard about memory leaking, this is not unique to the
>>>   
>> GTK library.  If the rumours are correct, applications like `ls` are
>> notorious for leaking memory, safe in the knowledge that the OS will
>> clean up after them.
>> 
> and if someone calls 'ls' iteratively in his program ?
>   
When a process finish, the OS clean up memory. However, on some cases, 
the cost to freeing the memory is greater than let to the OS.

-- 
Yours Truly,

   Junior Polegato

   A pilgrim of problems; A parchment of solutions!
   Professional Page: http://www.juniorpolegato.com.br

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: {Spam?} Re: memory leak in gtk

2007-11-24 Thread Vincent Torri


On Sat, 24 Nov 2007, Michael Lamothe wrote:

>> From what I've heard about memory leaking, this is not unique to the
> GTK library.  If the rumours are correct, applications like `ls` are
> notorious for leaking memory, safe in the knowledge that the OS will
> clean up after them.

and if someone calls 'ls' iteratively in his program ?

Vincent Torri
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list