Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 23 Aug 2019 17:43:42 +0000 (UTC)
From:      Ed Maste <emaste@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r351433 - stable/11/contrib/telnet/telnetd
Message-ID:  <201908231743.x7NHhgvM051611@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: emaste
Date: Fri Aug 23 17:43:41 2019
New Revision: 351433
URL: https://svnweb.freebsd.org/changeset/base/351433

Log:
  MFC r331074 (cem): telnetd(8): Fix dereference of uninitialized value 'IF'
  
  Reported by:	Coverity

Modified:
  stable/11/contrib/telnet/telnetd/telnetd.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/telnet/telnetd/telnetd.c
==============================================================================
--- stable/11/contrib/telnet/telnetd/telnetd.c	Fri Aug 23 17:40:47 2019	(r351432)
+++ stable/11/contrib/telnet/telnetd/telnetd.c	Fri Aug 23 17:43:41 2019	(r351433)
@@ -921,7 +921,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?201908231743.x7NHhgvM051611>