qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 2/3] qga: add implementation of guest-get-disks for Linux


From: Marc-André Lureau
Subject: Re: [PATCH v2 2/3] qga: add implementation of guest-get-disks for Linux
Date: Tue, 6 Oct 2020 12:40:58 +0400

Hi

On Tue, Oct 6, 2020 at 12:31 PM Tomáš Golembiovský <tgolembi@redhat.com> wrote:
On Tue, Sep 29, 2020 at 07:22:00PM +0400, Marc-André Lureau wrote:

> > +        if (getline(&line, &n, fp) == -1) {
> > +            g_debug("  failed to read disk size");
> >
>
> line: getline(3) "This buffer should be freed by the user program even if
> getline() failed."

That is handled by the g_autofree, or am I missing something? `line`
will get out of scope after every interation (even with continue). Or do

 
Ah right, I got confused.

thanks

--
Marc-André Lureau

reply via email to

[Prev in Thread] Current Thread [Next in Thread]