Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 4 Oct 2015 01:56:11 +0000 (UTC)
From:      Sean Bruno <sbruno@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r288645 - head/bin/cat
Message-ID:  <201510040156.t941uBbX033198@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: sbruno
Date: Sun Oct  4 01:56:11 2015
New Revision: 288645
URL: https://svnweb.freebsd.org/changeset/base/288645

Log:
  Initialize fd to -1 so that gcc doesn't emit an unitialized warning.

Modified:
  head/bin/cat/cat.c

Modified: head/bin/cat/cat.c
==============================================================================
--- head/bin/cat/cat.c	Sun Oct  4 00:40:12 2015	(r288644)
+++ head/bin/cat/cat.c	Sun Oct  4 01:56:11 2015	(r288645)
@@ -306,7 +306,8 @@ udom_open(const char *path, int flags)
 {
 	struct addrinfo hints, *res, *res0;
 	char rpath[PATH_MAX];
-	int fd, error;
+	int fd = -1;
+	int error;
 
 	/*
 	 * Construct the unix domain socket address and attempt to connect.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201510040156.t941uBbX033198>