<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
On 5/6/2013 12:10 PM, Mike Frysinger wrote:<br>
<span style="white-space: pre;">> On Monday 06 May 2013 11:21:13
Chris Metcalf wrote:<br>
>> -LC_ALL=C grep -x 'stat\(64\)\?("sample",
{st_mode=S_IFREG|0644, st_size=46118400000, \.\.\.}) \+= 0'
check.log > /dev/null ||<br>
>> +LC_ALL=C grep -x 'f\?stat\(at\)\?\(64\)\?(\(AT_FDCWD,
\)\?"sample", {st_mode=S_IFREG|0644, st_size=46118400000,
\.\.\.}\(, <br>
> 0\)\?) \+= 0' check.log > /dev/null ||<br>
><br>
> i know it's not a new issue w/your patch, but could you
change this to use<br>
> grep -E instead ? that will require a escaping the plain (
and ), but i think<br>
> that's better since the current syntax is not in POSIX afaik
and you end up<br>
> with less total escapes ...<br>
><br>
> LC_ALL=C grep -x 'f?stat(at)?(64)?\(((AT_FDCWD, )?"sample",
.........</span><br>
<br>
The regexp I modified certainly gets better, but the others get a
little worse due to the syscall parens and the pipe symbol in
"S_IFREG|0644". (Also, following the advice in the grep info page,
I use "[{]" to indicate a non-meta curly bracket, so that's a little
clunky too.) But it's still probably better on balance to use
egrep syntax.<br>
<br>
We could switch only the one I modified to use '-E', but that feels
really confusing to future folks who come and modify.<br>
<br>
I think the same risk of confusion is true of the fact that only one
of the tests doesn't use "-x"; I think it's better to add leading
and trailing ".*" to the regexps and use "-x" for that one too. In
the spirit of general cleanup I added that to my patch as well. See
following email; I tested the result on tilegx and x86_64.<br>
<br>
-- <br>
Chris Metcalf, Tilera Corp.<br>
<a class="moz-txt-link-freetext" href="http://www.tilera.com">http://www.tilera.com</a><br>
<br>
</body>
</html>