Re: [PATCH] libmm-glib: set clear func by default in the MMModemPortInfo array

2017-02-10 Thread Aleksander Morgado
On Thu, Feb 9, 2017 at 3:54 PM, Piotr Figiel wrote: > I tested your patch and the reported issue doesn't appear any longer. > It all looks good and certainly better (more glib-style) than my initial > implementation. Although I wonder if this doesn't ever collide with > mm_modem_port_info_array_

Re: [PATCH] libmm-glib: set clear func by default in the MMModemPortInfo array

2017-02-09 Thread Piotr Figiel
Hi Aleksander, I tested your patch and the reported issue doesn't appear any longer. It all looks good and certainly better (more glib-style) than my initial implementation. Although I wonder if this doesn't ever collide with mm_modem_port_info_array_free() in mm-helper-types.c? It seems that two

[PATCH] libmm-glib: set clear func by default in the MMModemPortInfo array

2017-02-08 Thread Aleksander Morgado
So that we don't leak the port names allocated within each MMModemPortInfo. ==261== 672 bytes in 84 blocks are definitely lost in loss record 7,314 of 7,383 ==261== at 0x402C51E: malloc (vg_replace_malloc.c:299) ==261== by 0x4484878: g_malloc (gmem.c:94) ==261== by 0x449D51D: g_st