[PATCH] mbimcli: use g_strfreev instead of g_free to free g_strsplit results
Ben Chan
benchan at chromium.org
Mon Feb 24 09:13:43 PST 2014
On Mon, Feb 24, 2014 at 9:04 AM, Aleksander Morgado <
aleksander at aleksander.es> wrote:
> On Mon, Feb 24, 2014 at 6:01 PM, Ben Chan <benchan at chromium.org> wrote:
> > How about g_strdup the strings being returned, and then g_strfreev the
> > string array? That's less efficient but makes the ownership transfer of
> the
> > allocated strings more obvious. Also, we don't need to assume how
> g_strsplit
> > actually allocates the string array as the glib API only suggests using
> > g_strfreev. How do you think?
>
> Yeah, let's do that, it's not a big deal.
>
Uploaded a revised patch. Sorry I forgot to tag it as v2 :)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/libmbim-devel/attachments/20140224/cd67fe45/attachment.html>
More information about the libmbim-devel
mailing list