-/* $OpenBSD: grid.c,v 1.41 2014/10/08 17:35:58 nicm Exp $ */
+/* $OpenBSD: grid.c,v 1.42 2015/04/23 07:45:50 deraadt Exp $ */
/*
* Copyright (c) 2008 Nicholas Marriott <nicm@users.sourceforge.net>
memcpy(dstl, srcl, sizeof *dstl);
if (srcl->cellsize != 0) {
- dstl->celldata = xcalloc(
+ dstl->celldata = xreallocarray(NULL,
srcl->cellsize, sizeof *dstl->celldata);
memcpy(dstl->celldata, srcl->celldata,
srcl->cellsize * sizeof *dstl->celldata);