Date: Wed, 20 Jul 2016 04:49:02 +0000 (UTC) From: "Pedro F. Giffuni" <pfg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r303065 - stable/10/usr.bin/sed Message-ID: <201607200449.u6K4n2CU036639@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: pfg Date: Wed Jul 20 04:49:01 2016 New Revision: 303065 URL: https://svnweb.freebsd.org/changeset/base/303065 Log: MFC r302973: sed(1): Fix off by one introduced in r299211. Detected by running the gsed tests. Submitted by: Mikhail Teterin PR: 195929 Modified: stable/10/usr.bin/sed/process.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.bin/sed/process.c ============================================================================== --- stable/10/usr.bin/sed/process.c Wed Jul 20 04:45:59 2016 (r303064) +++ stable/10/usr.bin/sed/process.c Wed Jul 20 04:49:01 2016 (r303065) @@ -440,7 +440,7 @@ substitute(struct s_command *cp) regexec_e(re, ps, REG_NOTBOL, 0, le, psl)); /* Did not find the requested number of matches. */ - if (n > 1) + if (n > 0) return (0); /* Copy the trailing retained string. */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201607200449.u6K4n2CU036639>