Update to FreeBSD head 2017-04-04

Git mirror commit 642b174daddbd0efd9bb5f242c43f4ab4db6869f.
This commit is contained in:
Sebastian Huber
2017-04-04 09:36:57 +02:00
parent 3360232e95
commit de8a76da2f
530 changed files with 26497 additions and 31504 deletions

View File

@@ -632,8 +632,8 @@ parse_ncp(char *stringp, struct netconfig *ncp)
ncp->nc_lookups = NULL;
ncp->nc_nlookups = 0;
while ((cp = tokenp) != NULL) {
if ((nc_lookups = realloc(ncp->nc_lookups,
(ncp->nc_nlookups + 1) * sizeof *ncp->nc_lookups)) == NULL) {
if ((nc_lookups = reallocarray(ncp->nc_lookups,
ncp->nc_nlookups + 1, sizeof(*ncp->nc_lookups))) == NULL) {
free(ncp->nc_lookups);
ncp->nc_lookups = NULL;
return (-1);