[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Incorrect signal handling under SYSV machines



Tony Kimball <alk@pobox.com> writes:

> Very strange indeed:

actually, no
 
> ; l='@(#)RELEASE VERSION HPC 2.0 TMrts 10.1-integration.2-FreeBSD/x86'
> ; echo $l
> @(#)RELEASE VERSION HPC 2.0 TMrts 10.1-integration.2-FreeBSD/x86
> ; k=`{strings lib/libtmrts_g.a | grep RELEASE\ VERSION | head -1| sed s,'"',,g}
> ; echo $k > k.out
> ; echo $l > l.out
> ; diff *.out
> ; expr $l : $e
> expr $l : $e
> HPC 2.0 TMrts 10.1-integration.2-FreeBSD/x86
> ; expr $k : $e
> expr $k : $e
> expr: syntax error
> 
> Go figure.  I might just crack the source out of curiousity on this
> one, unless some brilliant commentator can pre-emptively illuminate...

note that $#k and $#l are different.  One has spaces embedded in the
string, the other does not and is an array.

%read does not split strings on spaces.  But %backquote does.

Soren