Re: [systemd-devel] [PATCH 2/2] detect-virt: dmi: fix mem leak

2015-11-04 Thread Andrew Jones
On Wed, Nov 04, 2015 at 08:26:00AM -0600, Andrew Jones wrote: > On Wed, Nov 04, 2015 at 11:46:22AM +0100, Lennart Poettering wrote: > > On Tue, 03.11.15 15:04, Andrew Jones (drjo...@redhat.com) wrote: > > > > > The variable 's' is still in scope until we exit the function. We > > > can't call read

Re: [systemd-devel] [PATCH 2/2] detect-virt: dmi: fix mem leak

2015-11-04 Thread Andrew Jones
On Wed, Nov 04, 2015 at 11:46:22AM +0100, Lennart Poettering wrote: > On Tue, 03.11.15 15:04, Andrew Jones (drjo...@redhat.com) wrote: > > > The variable 's' is still in scope until we exit the function. We > > can't call read_one_line_file on it multiple times without calling > > free in between.

Re: [systemd-devel] [PATCH 2/2] detect-virt: dmi: fix mem leak

2015-11-04 Thread Lennart Poettering
On Tue, 03.11.15 15:04, Andrew Jones (drjo...@redhat.com) wrote: > The variable 's' is still in scope until we exit the function. We > can't call read_one_line_file on it multiple times without calling > free in between. > --- > src/basic/virt.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 del

Re: [systemd-devel] [PATCH 2/2] detect-virt: dmi: fix mem leak

2015-11-03 Thread systemd github import bot
Patchset imported to github. To create a pull request, one of the main developers has to initiate one via: -- Generated by https://github.com/haraldh/mail2git _

[systemd-devel] [PATCH 2/2] detect-virt: dmi: fix mem leak

2015-11-03 Thread Andrew Jones
The variable 's' is still in scope until we exit the function. We can't call read_one_line_file on it multiple times without calling free in between. --- src/basic/virt.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/basic/virt.c b/src/basic/virt.c index 1e10fc755f20