Re: GLib questions, GArray and GNode

2008-03-28 Thread Kaustubh Patil
Dear Jordan, Thanks for quick answer. I am not very good in extensive pointer programming. So it will be very nice of you if you can clarify some more things. 1. Is the following function ok? GArray* g_array_clone(GArray *array) { int i; GArray *clone = g_array_new(FALSE,FALSE,sizeof(long));

Re: GLib questions, GArray and GNode

2008-03-28 Thread Jordan Walsh
On Thu, 2008-03-27 at 10:01 -0700, Kaustubh Patil wrote: > Hi, > > I am using glib (version 2.0) for developing some > applications. I have some questions about use of > Garray and GNode (G-n-ary tree). > > 1. Is it safe to return an initialized GArray * from a > function? e.g. copying garray arr

GLib questions, GArray and GNode

2008-03-27 Thread Kaustubh Patil
Hi, I am using glib (version 2.0) for developing some applications. I have some questions about use of Garray and GNode (G-n-ary tree). 1. Is it safe to return an initialized GArray * from a function? e.g. copying garray array1 into garray array2 and then returning pointer to array2. 2. For n-ar