malloc(M_WAITOK) never fails, so there is no need to check for NULL.

This commit is contained in:
Pawel Jakub Dawidek 2011-11-26 23:18:19 +00:00
parent 0e4fb1db44
commit 5be4c9b9e6
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=228011

View File

@ -195,10 +195,6 @@ esp_init(struct secasvar *sav, struct xformsw *xsp)
*/
sav->ivlen = (txform == &enc_xform_null ? 0 : txform->blocksize);
sav->iv = (caddr_t) malloc(sav->ivlen, M_XDATA, M_WAITOK);
if (sav->iv == NULL) {
DPRINTF(("%s: no memory for IV\n", __func__));
return EINVAL;
}
key_randomfill(sav->iv, sav->ivlen); /*XXX*/
/*