Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 2 Jun 2019 20:47:15 +0000 (UTC)
From:      Warner Losh <imp@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r348518 - head/contrib/one-true-awk
Message-ID:  <201906022047.x52KlFsZ079218@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: imp
Date: Sun Jun  2 20:47:15 2019
New Revision: 348518
URL: https://svnweb.freebsd.org/changeset/base/348518

Log:
  Reapply r301691:
  
  Revert r301689 - one-true-awk: Avoid a NULL dereference.
  
  I got this wrong and the coverity report doesn't match the NetBSD change,
  which was thought for a different version.
  
  The change wouldn't hurt but let's wait until upstream figures this out.

Modified:
  head/contrib/one-true-awk/tran.c

Modified: head/contrib/one-true-awk/tran.c
==============================================================================
--- head/contrib/one-true-awk/tran.c	Sun Jun  2 20:03:00 2019	(r348517)
+++ head/contrib/one-true-awk/tran.c	Sun Jun  2 20:47:15 2019	(r348518)
@@ -366,7 +366,7 @@ char *setsval(Cell *vp, const char *s)	/* set string v
 		if (donerec == 0)
 			recbld();
 	}
-	t = s ? tostring(s) : tostring("");	/* in case it's self-assign */
+	t = tostring(s);	/* in case it's self-assign */
 	if (freeable(vp))
 		xfree(vp->sval);
 	vp->tval &= ~(NUM|CONVC|CONVO);



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