[Top][All Lists]

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

bash: remove the format string "%q" in the unicode3.sub

From: address@hidden
Subject: bash: remove the format string "%q" in the unicode3.sub
Date: Tue, 9 Aug 2016 15:18:17 +0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2

Hi all

When I run the tests for the bash, the sub-test unicode3.sub of intl.tests failed.

The sub-test unicode3.sub contain the following:

    printf %q "$payload"

In this situation, the format string "%q" in command printf means that when the
character in the payload is not in {alpha & digit & punctuation & ISO 646(7-bit)}, it
would print the string with ANSI-C style quoted string: $'...' , we can check the source code


Because the payload variable contain the above situation, so the test results look like $'...' ,
when compared with the intl.right that contain the converted character(extended ASCII), so
the test failed.

Can we remove the format string "%q", so just

     printf "$payload"

In this way, the output of test is same as the intl.right.


reply via email to

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