[lxc-devel] [PATCH 2/2] fix some larger memory leaks in cgroup code

Dwight Engen dwight.engen at oracle.com
Wed Sep 25 20:42:38 UTC 2013


On Wed, 25 Sep 2013 15:08:37 -0500
Serge Hallyn <serge.hallyn at ubuntu.com> wrote:

> Quoting Dwight Engen (dwight.engen at oracle.com):
> > On Wed, 25 Sep 2013 14:44:07 -0400
> > S.Çağlar Onur <caglar at 10ur.org> wrote:
> > 
> > > Uhh something is wrong with this commit
> > 
> > Hey Serge, I think this has to do with the rebase after the split
> > up as it certinaly wasn't seg faulting on me originally. The split
> > also
> 
> Yeah, sorry.  I'd lost the free(line) when moving code.  I'm not quite
> sure how the lxc_cgroup_process_info_free(info) at the out3: label
> could have actually worked for you, but maybe I dropped a zeroing out

Hmm, yeah I'm not sure why I didn't hit that in my testing with
lxc-test-concurrent. I agree with you that it shouldn't be free()ed
as it just points at one of the info's of base_info and isn't a new
alloc.

> of something somewhere.
> 
> > appears to have introduced a couple new leaks (ie. line in the
> > subfunctions). Do you want me to just redo the cleanup fds & memory
> > stuff on top of your change?
> 
> If you see any more bits I stupidly dropped in current git head,
> please do.  I'm going to get going on the selinux patch now.

Okay, it looks like you didn't merge any of the first one ("cleanup
fds, memory in lxc_cgroup_load_meta2()") so I'll look at rebasing that
on git head, re-valgrind, and resubmit. Thanks.

> thanks,
> -serge




More information about the lxc-devel mailing list