PR 51003 David Binderman: bzero struct before passing it around.

This is actually unnecessary as the call in question uses only fields
that have been set explicitly, but good practice regardless and it's
not like it's on a performance-critical path.
This commit is contained in:
dholland 2016-05-31 03:47:49 +00:00
parent 39a10a6851
commit 7dae429fbd
1 changed files with 3 additions and 2 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: zic.c,v 1.57 2016/03/15 15:16:01 christos Exp $ */
/* $NetBSD: zic.c,v 1.58 2016/05/31 03:47:49 dholland Exp $ */
/*
** This file is in the public domain, so clarified as of
** 2006-07-17 by Arthur David Olson.
@ -10,7 +10,7 @@
#include <sys/cdefs.h>
#ifndef lint
__RCSID("$NetBSD: zic.c,v 1.57 2016/03/15 15:16:01 christos Exp $");
__RCSID("$NetBSD: zic.c,v 1.58 2016/05/31 03:47:49 dholland Exp $");
#endif /* !defined lint */
#include "private.h"
@ -2551,6 +2551,7 @@ error(_("can't determine time zone abbreviation to use just after until time"));
*/
struct rule xr;
struct attype *lastat;
memset(&xr, 0, sizeof(xr));
xr.r_month = TM_JANUARY;
xr.r_dycode = DC_DOM;
xr.r_dayofmonth = 1;