Fix calloc(3) argument order.

Reviewed by:	trasz
MFC after:	4 weeks.
Differential Revision:	https://reviews.freebsd.org/D7532
This commit is contained in:
Marcelo Araujo 2016-08-22 15:01:39 +00:00
parent c7d40f1843
commit f3ccb446d2
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=304605
6 changed files with 10 additions and 10 deletions

View File

@ -232,7 +232,7 @@ chap_new(void)
{
struct chap *chap;
chap = calloc(sizeof(*chap), 1);
chap = calloc(1, sizeof(*chap));
if (chap == NULL)
log_err(1, "calloc");
@ -333,7 +333,7 @@ rchap_new(const char *secret)
{
struct rchap *rchap;
rchap = calloc(sizeof(*rchap), 1);
rchap = calloc(1, sizeof(*rchap));
if (rchap == NULL)
log_err(1, "calloc");

View File

@ -43,7 +43,7 @@ keys_new(void)
{
struct keys *keys;
keys = calloc(sizeof(*keys), 1);
keys = calloc(1, sizeof(*keys));
if (keys == NULL)
log_err(1, "calloc");

View File

@ -81,11 +81,11 @@ pdu_new(struct connection *conn)
{
struct pdu *pdu;
pdu = calloc(sizeof(*pdu), 1);
pdu = calloc(1, sizeof(*pdu));
if (pdu == NULL)
log_err(1, "calloc");
pdu->pdu_bhs = calloc(sizeof(*pdu->pdu_bhs), 1);
pdu->pdu_bhs = calloc(1, sizeof(*pdu->pdu_bhs));
if (pdu->pdu_bhs == NULL)
log_err(1, "calloc");

View File

@ -232,7 +232,7 @@ chap_new(void)
{
struct chap *chap;
chap = calloc(sizeof(*chap), 1);
chap = calloc(1, sizeof(*chap));
if (chap == NULL)
log_err(1, "calloc");
@ -333,7 +333,7 @@ rchap_new(const char *secret)
{
struct rchap *rchap;
rchap = calloc(sizeof(*rchap), 1);
rchap = calloc(1, sizeof(*rchap));
if (rchap == NULL)
log_err(1, "calloc");

View File

@ -43,7 +43,7 @@ keys_new(void)
{
struct keys *keys;
keys = calloc(sizeof(*keys), 1);
keys = calloc(1, sizeof(*keys));
if (keys == NULL)
log_err(1, "calloc");

View File

@ -81,11 +81,11 @@ pdu_new(struct connection *conn)
{
struct pdu *pdu;
pdu = calloc(sizeof(*pdu), 1);
pdu = calloc(1, sizeof(*pdu));
if (pdu == NULL)
log_err(1, "calloc");
pdu->pdu_bhs = calloc(sizeof(*pdu->pdu_bhs), 1);
pdu->pdu_bhs = calloc(1, sizeof(*pdu->pdu_bhs));
if (pdu->pdu_bhs == NULL)
log_err(1, "calloc");