svn commit: r251560 - head/usr.sbin/pkg

Baptiste Daroussin bapt at FreeBSD.org
Sat Jun 8 23:48:14 UTC 2013


Author: bapt
Date: Sat Jun  8 23:48:13 2013
New Revision: 251560
URL: http://svnweb.freebsd.org/changeset/base/251560

Log:
  Fix a bad calloc(3) call
  
  MFC after:	2 weeks

Modified:
  head/usr.sbin/pkg/dns_utils.c

Modified: head/usr.sbin/pkg/dns_utils.c
==============================================================================
--- head/usr.sbin/pkg/dns_utils.c	Sat Jun  8 23:45:11 2013	(r251559)
+++ head/usr.sbin/pkg/dns_utils.c	Sat Jun  8 23:48:13 2013	(r251560)
@@ -66,7 +66,7 @@ dns_getsrvinfo(const char *zone)
 		p += len + NS_QFIXEDSZ;
 	}
 
-	res = calloc(ancount, sizeof(struct dns_srvinfo));
+	res = calloc(ancount, sizeof(struct dns_srvinfo *));
 	if (res == NULL)
 		return (NULL);
 


More information about the svn-src-head mailing list