bin/80868: /bin/sh gives wrong line number of unterminated quoted
string error
Daniel Rudy
dr2867.business at pacbell.net
Tue May 10 20:40:02 GMT 2005
>Number: 80868
>Category: bin
>Synopsis: /bin/sh gives wrong line number of unterminated quoted string error
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Tue May 10 20:40:01 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator: Daniel Rudy
>Release: 5.3-RELEASE-p6
>Organization:
>Environment:
FreeBSD wildfire.danielrudy.org 5.3-RELEASE-p6 FreeBSD 5.3-RELEASE-p6 #2: Wed Mar 30 06:30:41 PST 2005 root at strata:/usr/obj/usr/src/sys/WILDFIRE i386
>Description:
When using borne shell scripts (/bin/sh) and there is a coding error in the script which results in a unterminated quoted string, /bin/sh gives the wrong line number of the error.
>How-To-Repeat:
Consider the following script:
unquote:
#!/bin/sh
echo "quote 1"
echo "quote 2
echo "quote 3"
echo "quote 4"
will yeild the following output:
./unquote: 6: Syntax error: Unterminated quoted string
It should be indicating that the error is on line 4, not line 6. This causes a real hassle to find a unquoted terminated string if you have a large script with many strings.
>Fix:
Unknown.
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-bugs
mailing list