Date: Mon, 22 Feb 2010 15:58:10 +0000 (UTC) From: Ruslan Ermilov <ru@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r204203 - stable/8/lib/libjail Message-ID: <201002221558.o1MFwANN089820@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: ru Date: Mon Feb 22 15:58:10 2010 New Revision: 204203 URL: http://svn.freebsd.org/changeset/base/204203 Log: MFC: r204008: realloc() with a proper amount of memory. Modified: stable/8/lib/libjail/jail.c Directory Properties: stable/8/lib/libjail/ (props changed) Modified: stable/8/lib/libjail/jail.c ============================================================================== --- stable/8/lib/libjail/jail.c Mon Feb 22 15:57:36 2010 (r204202) +++ stable/8/lib/libjail/jail.c Mon Feb 22 15:58:10 2010 (r204203) @@ -191,7 +191,7 @@ jailparam_all(struct jailparam **jpp) /* Add the parameter to the list */ if (njp >= nlist) { nlist *= 2; - jp = realloc(jp, nlist * sizeof(jp)); + jp = realloc(jp, nlist * sizeof(*jp)); if (jp == NULL) { jailparam_free(jp, njp); return (-1);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201002221558.o1MFwANN089820>