Re: [systemd-devel] [PATCH 1/2] selinux: fix potential double free crash in child process

2014-10-24 Thread Zbigniew Jędrzejewski-Szmek
On Mon, Oct 13, 2014 at 04:57:12PM +0200, Michal Sekletar wrote: > Before returning from function we should reset ret to NULL, thus cleanup > function is nop. > > Also context_str() returns pointer to a string containing context but not a > copy, hence we must make copy it explicitly. > --- > src

Re: [systemd-devel] [PATCH 1/2] selinux: fix potential double free crash in child process

2014-10-15 Thread Michal Sekletar
On Mon, Oct 13, 2014 at 05:14:24PM +0200, Zbigniew Jędrzejewski-Szmek wrote: > On Mon, Oct 13, 2014 at 04:57:12PM +0200, Michal Sekletar wrote: > > Before returning from function we should reset ret to NULL, thus cleanup > > function is nop. > > > > Also context_str() returns pointer to a string c

[systemd-devel] [PATCH 1/2] selinux: fix potential double free crash in child process

2014-10-13 Thread Michal Sekletar
Before returning from function we should reset ret to NULL, thus cleanup function is nop. Also context_str() returns pointer to a string containing context but not a copy, hence we must make copy it explicitly. --- src/shared/label.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff