Author: ru Date: Wed Feb 17 16:45:03 2010 New Revision: 204008 URL: http://svn.freebsd.org/changeset/base/204008
Log: realloc() with a proper amount of memory. MFC after: 3 days Modified: head/lib/libjail/jail.c Modified: head/lib/libjail/jail.c ============================================================================== --- head/lib/libjail/jail.c Wed Feb 17 15:44:01 2010 (r204007) +++ head/lib/libjail/jail.c Wed Feb 17 16:45:03 2010 (r204008) @@ -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); _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"