AF:
NF:0
PS:10
SRH:1
SFN:
DSR:
MID:
CFG:
PT:0
S:andy.sharp@lsi.com
RQ:
SSV:mhbs.lsil.com
NSV:
SSH:
R:<Ed.Kwan@lsi.com>
MAID:2
X-Sylpheed-Privacy-System:
X-Sylpheed-Sign:0
SCF:#mh/Mailbox/sent
RMID:#imap/LSI/INBOX	0	2B044E14371DA244B71F8BF2514563F5042805A1@cosmail03.lsi.com
X-Sylpheed-End-Special-Headers: 1
Date: Thu, 17 Dec 2009 18:11:37 -0800
From: Andrew Sharp <andy.sharp@lsi.com>
To: "Kwan, Ed" <Ed.Kwan@lsi.com>
Subject: Re: please review code change for TED 27867 Using "*" in vscan
 extension causes syntax error in SGA
Message-ID: <20091217181137.3ae175a7@ripper.onstor.net>
In-Reply-To: <2B044E14371DA244B71F8BF2514563F5042805A1@cosmail03.lsi.com>
References: <2B044E14371DA244B71F8BF2514563F504280553@cosmail03.lsi.com>
	<20091217170337.7b57b629@ripper.onstor.net>
	<2B044E14371DA244B71F8BF2514563F5042805A1@cosmail03.lsi.com>
Organization: LSI
X-Mailer: Sylpheed-Claws 2.6.0 (GTK+ 2.8.20; x86_64-pc-linux-gnu)
Mime-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit

I'm not sure I understand what you're trying to tell me.  It seems to
be able to absorb a single star all by itself.  Which actually
surprises me a little bit.  But I guess once it sees the colon it's OK.

This is what worries me:


ripper:~$ ./s
<rtCode>*.pdf</rtCode>
rc not NULL C-standard.pdf ReleaseNotes-4.0.0.pdf SB-1_WP100-R.pdf Velocity1000_DS_0409.pdf dmv-plate-replacement.pdf ds_755p_sprint.pdf milestone-summary-tuxrx.pdf mips_asm_prog_guide.pdf onstor_directory.pdf perforce_introduction.pdf sequoia.pdf treo_755p.pdf udev-persistent-naming.pdf window_estimate.pdf




On Thu, 17 Dec 2009 18:45:43 -0700 "Kwan, Ed" <Ed.Kwan@lsi.com> wrote:

> The problem is "*" is an operator to expr.
> Not related to expanding "*".
>  
> [edk@edk-linux /tmp]$ cat s
> #!/bin/sh
> 
> read -r line
> rc=`expr " $line" : ' <rtCode>\(.*\)</rtCode>'`
> if [ "$rc" == "" ]
> then
>         echo -E "$line"
> else
>         echo rc not NULL $rc
> fi
> 
> [edk@edk-linux /tmp]$ ./s
> a
> a
> 
> [edk@edk-linux /tmp]$ ./s
> *
> *
> 
> [edk@edk-linux /tmp]$ ./s
> <rtCode>junk</rtCode>
> rc not NULL junk
> 
> 
> -----Original Message-----
> From: Andrew Sharp [mailto:andy.sharp@lsi.com] 
> Sent: Thursday, December 17, 2009 5:04 PM
> To: Kwan, Ed
> Subject: Re: please review code change for TED 27867 Using "*" in
> vscan extension causes syntax error in SGA
> 
> On Thu, 17 Dec 2009 16:06:52 -0700 "Kwan, Ed" <Ed.Kwan@lsi.com> wrote:
> 
> > Change 34063
> 
> 
> = Change 34063 by edk@edk-dev on 2009/12/17 15:05:47 *pending*
> = 
> = 	For TED 27867 Using "*" in vscan extension causes syntax
> error in SGA = 	Added an "X" in the string pattern so that
> "expr" doesn't get confused. = 	Reviewed by
> = 
> 
> nfx-tree/code/ssc-support/support.sh
> 
>      i don't think will do what you want, because the '*' might still
>      be in $rc, where it might get expanded in line 653.  also, i
> don't understand why this does anything to help expr.  maybe you just
>      need double quotes around the `expr foo` part to keep the '*'
>      from expanding.  and on line 653.  testing?
> 
