From owner-cvs-src-old@FreeBSD.ORG Sun Oct 24 20:45:48 2010 Return-Path: Delivered-To: cvs-src-old@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 18CC41065674 for ; Sun, 24 Oct 2010 20:45:48 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 05C9C8FC18 for ; Sun, 24 Oct 2010 20:45:48 +0000 (UTC) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.4/8.14.4) with ESMTP id o9OKjltp015472 for ; Sun, 24 Oct 2010 20:45:47 GMT (envelope-from jilles@repoman.freebsd.org) Received: (from svn2cvs@localhost) by repoman.freebsd.org (8.14.4/8.14.4/Submit) id o9OKjlx4015471 for cvs-src-old@freebsd.org; Sun, 24 Oct 2010 20:45:47 GMT (envelope-from jilles@repoman.freebsd.org) Message-Id: <201010242045.o9OKjlx4015471@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: svn2cvs set sender to jilles@repoman.freebsd.org using -f From: Jilles Tjoelker Date: Sun, 24 Oct 2010 20:45:13 +0000 (UTC) To: cvs-src-old@freebsd.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/bin/sh parser.c src/tools/regression/bin/sh/parser func1.0 X-BeenThere: cvs-src-old@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: **OBSOLETE** CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Oct 2010 20:45:48 -0000 jilles 2010-10-24 20:45:13 UTC FreeBSD src repository Modified files: bin/sh parser.c Added files: tools/regression/bin/sh/parser func1.0 Log: SVN rev 214291 on 2010-10-24 20:45:13Z by jilles sh: Make sure defined functions can actually be called. Add some conservative checks on function names: - Disallow expansions or quoting characters; these can only be called via strange control characters - Disallow '/'; these functions cannot be called anyway, as exec.c assumes they are pathnames - Make the CTL* bytes work properly in function names. These are syntax errors. POSIX does not require us to support more than names (letters, digits and underscores, not starting with a digit), but I do not want to restrict it that much at this time. Exp-run done by: pav (with some other sh(1) changes) Revision Changes Path 1.90 +7 -3 src/bin/sh/parser.c 1.1 +25 -0 src/tools/regression/bin/sh/parser/func1.0 (new)