lib: use strzero where applicable
Replace `memzero (s, strlen(s))` with just the internal wrapper `strzero (s)` where the underlying allocated size is not known.
This commit is contained in:
committed by
Iker Pedrosa
parent
14e7caf6b2
commit
e74bfe2c75
@ -128,7 +128,7 @@ void sgr_free (/*@out@*/ /*@only@*/struct sgrp *sgent)
|
||||
size_t i;
|
||||
free (sgent->sg_name);
|
||||
if (NULL != sgent->sg_passwd) {
|
||||
memzero (sgent->sg_passwd, strlen (sgent->sg_passwd));
|
||||
strzero (sgent->sg_passwd);
|
||||
free (sgent->sg_passwd);
|
||||
}
|
||||
for (i = 0; NULL != sgent->sg_adm[i]; i++) {
|
||||
|
Reference in New Issue
Block a user