On Thu, Aug 11, 2011 at 9:04 AM, Jan Safranek <jsafr...@redhat.com> wrote:
> Free the cgroup on error.
>
> Signed-off-by: Jan Safranek <jsafr...@redhat.com>

Acked-by: Dhaval Giani <dhaval.gi...@gmail.com>

> ---
>
>  tests/test_functions.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/tests/test_functions.c b/tests/test_functions.c
> index 796a2af..8f1d59e 100644
> --- a/tests/test_functions.c
> +++ b/tests/test_functions.c
> @@ -552,12 +552,14 @@ struct cgroup *new_cgroup(char *group, char 
> *controller_name,
>                        } else {
>                                message(i++, FAIL, wr, retval ,
>                                                         info[NOMESSAGE]);
> +                               cgroup_free(&newcgroup);
>                                return NULL;
>                        }
>                 } else {
>                        /* Since these wrappers do not return an int so -1 */
>                        message(i++, FAIL, "add_controller", -1,
>                                                         info[NOMESSAGE]);
> +                       cgroup_free(&newcgroup);
>                        return NULL;
>                }
>        } else {
>
>
> ------------------------------------------------------------------------------
> Get a FREE DOWNLOAD! and learn more about uberSVN rich system,
> user administration capabilities and model configuration. Take
> the hassle out of deploying and managing Subversion and the
> tools developers use with it.
> http://p.sf.net/sfu/wandisco-dev2dev
> _______________________________________________
> Libcg-devel mailing list
> Libcg-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/libcg-devel
>

------------------------------------------------------------------------------
Get a FREE DOWNLOAD! and learn more about uberSVN rich system, 
user administration capabilities and model configuration. Take 
the hassle out of deploying and managing Subversion and the 
tools developers use with it. 
http://p.sf.net/sfu/wandisco-dev2dev
_______________________________________________
Libcg-devel mailing list
Libcg-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libcg-devel

Reply via email to