Skip to content

Commit f647a6b

Browse files
committed
GitHub issue #1: jlduran: Initialize dbi so that the debug print does not
print junk.
1 parent a023a9a commit f647a6b

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

external/bsd/blocklist/bin/blocklistd.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* $NetBSD: blocklistd.c,v 1.8 2025/02/11 17:48:30 christos Exp $ */
1+
/* $NetBSD: blocklistd.c,v 1.9 2025/03/26 00:12:49 christos Exp $ */
22

33
/*-
44
* Copyright (c) 2015 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
3535
#ifdef HAVE_SYS_CDEFS_H
3636
#include <sys/cdefs.h>
3737
#endif
38-
__RCSID("$NetBSD: blocklistd.c,v 1.8 2025/02/11 17:48:30 christos Exp $");
38+
__RCSID("$NetBSD: blocklistd.c,v 1.9 2025/03/26 00:12:49 christos Exp $");
3939

4040
#include <sys/types.h>
4141
#include <sys/socket.h>
@@ -178,6 +178,7 @@ process(bl_t bl)
178178
struct dbinfo dbi;
179179
struct timespec ts;
180180

181+
memset(&dbi, 0, sizeof(dbi));
181182
if (clock_gettime(CLOCK_REALTIME, &ts) == -1) {
182183
(*lfun)(LOG_ERR, "clock_gettime failed (%m)");
183184
return;

0 commit comments

Comments
 (0)