Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin appease gcc -Wuninitialized
details: https://anonhg.NetBSD.org/src/rev/4c03490023b2
branches: trunk
changeset: 581485:4c03490023b2
user: lukem <lukem%NetBSD.org@localhost>
date: Thu Jun 02 03:00:19 2005 +0000
description:
appease gcc -Wuninitialized
diffstat:
usr.bin/sockstat/sockstat.c | 6 +++---
usr.bin/tail/forward.c | 10 +++++-----
2 files changed, 8 insertions(+), 8 deletions(-)
diffs (60 lines):
diff -r 9fe1f28bc3f0 -r 4c03490023b2 usr.bin/sockstat/sockstat.c
--- a/usr.bin/sockstat/sockstat.c Thu Jun 02 02:46:16 2005 +0000
+++ b/usr.bin/sockstat/sockstat.c Thu Jun 02 03:00:19 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sockstat.c,v 1.6 2005/04/09 02:10:27 atatat Exp $ */
+/* $NetBSD: sockstat.c,v 1.7 2005/06/02 03:00:19 lukem Exp $ */
/*
* Copyright (c) 2005 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: sockstat.c,v 1.6 2005/04/09 02:10:27 atatat Exp $");
+__RCSID("$NetBSD: sockstat.c,v 1.7 2005/06/02 03:00:19 lukem Exp $");
#endif
#include <sys/param.h>
@@ -604,7 +604,7 @@
print_addr(int l, int t, int f, struct sockaddr *sa)
{
char sabuf[256], pbuf[32];
- int r;
+ int r = 0;
if (!(f & INP_ANONPORT))
f = 0;
diff -r 9fe1f28bc3f0 -r 4c03490023b2 usr.bin/tail/forward.c
--- a/usr.bin/tail/forward.c Thu Jun 02 02:46:16 2005 +0000
+++ b/usr.bin/tail/forward.c Thu Jun 02 03:00:19 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: forward.c,v 1.26 2004/02/16 21:57:04 itojun Exp $ */
+/* $NetBSD: forward.c,v 1.27 2005/06/02 03:07:00 lukem Exp $ */
/*-
* Copyright (c) 1991, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)forward.c 8.1 (Berkeley) 6/6/93";
#endif
-__RCSID("$NetBSD: forward.c,v 1.26 2004/02/16 21:57:04 itojun Exp $");
+__RCSID("$NetBSD: forward.c,v 1.27 2005/06/02 03:07:00 lukem Exp $");
#endif /* not lint */
#include <sys/types.h>
@@ -281,11 +281,11 @@
{
off_t file_size;
off_t file_remaining;
- char *p;
- char *start;
+ char *p = NULL;
+ char *start = NULL;
off_t mmap_size;
off_t mmap_offset;
- off_t mmap_remaining;
+ off_t mmap_remaining = 0;
#define MMAP_MAXSIZE (10 * 1024 * 1024)
Home |
Main Index |
Thread Index |
Old Index