Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 26 Oct 2018 21:56:10 +0000 (UTC)
From:      Tobias Kortkamp <tobik@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r483060 - in head/sysutils/yank: . files
Message-ID:  <201810262156.w9QLuANx018994@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: tobik
Date: Fri Oct 26 21:56:10 2018
New Revision: 483060
URL: https://svnweb.freebsd.org/changeset/ports/483060

Log:
  sysutils/yank: fix crash when using -g with -l

Added:
  head/sysutils/yank/files/patch-yank.c   (contents, props changed)
Modified:
  head/sysutils/yank/Makefile

Modified: head/sysutils/yank/Makefile
==============================================================================
--- head/sysutils/yank/Makefile	Fri Oct 26 21:35:38 2018	(r483059)
+++ head/sysutils/yank/Makefile	Fri Oct 26 21:56:10 2018	(r483060)
@@ -2,7 +2,7 @@
 
 PORTNAME=	yank
 DISTVERSION=	1.0.0
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	sysutils
 MASTER_SITES=	https://github.com/mptre/yank/releases/download/v${DISTVERSION}/
 

Added: head/sysutils/yank/files/patch-yank.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/yank/files/patch-yank.c	Fri Oct 26 21:56:10 2018	(r483060)
@@ -0,0 +1,12 @@
+--- yank.c.orig	2018-09-09 07:45:36 UTC
++++ yank.c
+@@ -430,7 +430,8 @@ main(int argc, char *argv[])
+ 			break;
+ 		case 'g':
+ 			free(pat);
+-			pat = optarg;
++			if ((pat = strdup(optarg)) == NULL)
++				err(1, NULL);
+ 			rflags |= REG_NEWLINE;
+ 			break;
+ 		case 'i':



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