Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 16 Mar 2018 20:59:56 +0000 (UTC)
From:      Conrad Meyer <cem@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r331074 - head/contrib/telnet/telnetd
Message-ID:  <201803162059.w2GKxup1037883@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: cem
Date: Fri Mar 16 20:59:56 2018
New Revision: 331074
URL: https://svnweb.freebsd.org/changeset/base/331074

Log:
  telnetd(8): Fix dereference of uninitialized value 'IF'
  
  Reported by:	Coverity
  Sponsored by:	Dell EMC Isilon

Modified:
  head/contrib/telnet/telnetd/telnetd.c

Modified: head/contrib/telnet/telnetd/telnetd.c
==============================================================================
--- head/contrib/telnet/telnetd/telnetd.c	Fri Mar 16 20:43:40 2018	(r331073)
+++ head/contrib/telnet/telnetd/telnetd.c	Fri Mar 16 20:59:56 2018	(r331074)
@@ -925,7 +925,7 @@ telnet(int f, int p, char *host)
 	edithost(HE, host_name);
 	if (hostinfo && *IM)
 		putf(IM, ptyibuf2);
-	if (IF && if_fd != -1) {
+	if (if_fd != -1) {
 		if (fstat(if_fd, &statbuf) != -1 && statbuf.st_size > 0) {
 			if_buf = (char *) mmap (0, statbuf.st_size,
 			    PROT_READ, 0, if_fd, 0);



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