-/* $OpenBSD: umac.c,v 1.1 2007/06/07 19:37:34 pvalchev Exp $ */
+/* $OpenBSD: umac.c,v 1.2 2007/09/12 19:39:19 stevesk Exp $ */
/* -----------------------------------------------------------------------
*
* umac.c -- C Implementation UMAC Message Authentication
#include "includes.h"
#include <sys/types.h>
+#include "xmalloc.h"
#include "umac.h"
#include <string.h>
#include <stdlib.h>
if (ctx) {
if (ALLOC_BOUNDARY)
ctx = (struct umac_ctx *)ctx->free_ptr;
- free(ctx);
+ xfree(ctx);
}
return (1);
}
size_t bytes_to_add;
aes_int_key prf_key;
- octx = ctx = malloc(sizeof(*ctx) + ALLOC_BOUNDARY);
+ octx = ctx = xmalloc(sizeof(*ctx) + ALLOC_BOUNDARY);
if (ctx) {
if (ALLOC_BOUNDARY) {
bytes_to_add = ALLOC_BOUNDARY -