qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] qemu-iotests: Filter out DOS line endings


From: Kevin Wolf
Subject: Re: [Qemu-devel] [PATCH] qemu-iotests: Filter out DOS line endings
Date: Thu, 01 Mar 2012 10:09:43 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.1) Gecko/20120209 Thunderbird/10.0.1

Am 29.02.2012 18:32, schrieb Eric Blake:
> On 02/29/2012 06:59 AM, Kevin Wolf wrote:
>> This one makes it possible to run qemu-iotests on a Windows build using Wine
>> and get somewhat meaningful results.
>>
>> Signed-off-by: Kevin Wolf <address@hidden>
>> ---
>>  tests/qemu-iotests/common.filter |    8 +++++++-
>>  1 files changed, 7 insertions(+), 1 deletions(-)
>>
>> diff --git a/tests/qemu-iotests/common.filter 
>> b/tests/qemu-iotests/common.filter
>> index da77ede..fa26b62 100644
>> --- a/tests/qemu-iotests/common.filter
>> +++ b/tests/qemu-iotests/common.filter
>> @@ -140,10 +140,16 @@ _filter_imgfmt()
>>      sed -e "s#$IMGFMT#IMGFMT#g"
>>  }
>>  
>> +# Removes \r from messages
>> +_filter_win32()
>> +{
>> +    sed -e 's/\r//g'
> 
> POSIX does not require sed to recognize \r as a synonym for carriage
> return.  You are better off using tr(1) (tr -d '\r') if all you want to
> do is strip carriage returns in a POSIX-compliant manner.  Also be aware
> that on Solaris, you have to make sure you are using a PATH that first
> finds a POSIX-compliant tr.

But who will run qemu-iotests on Wine on Solaris? Running it on Wine on
Linux is already crazy enough. IIUC the sed call won't break anything,
it may just not work and won't strip out the carriage returns. Well, bad
luck, try a sane setup instead.

(I would see it different if this was ./configure, but it is a test case
output filter)

Kevin



reply via email to

[Prev in Thread] Current Thread [Next in Thread]