lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <VI1P193MB0752CD67E1432A1CDE48F86D99A2A@VI1P193MB0752.EURP193.PROD.OUTLOOK.COM>
Date:   Mon, 30 Oct 2023 05:23:34 +0800
From:   Juntong Deng <juntong.deng@...look.com>
To:     Waiman Long <longman@...hat.com>, lizefan.x@...edance.com,
        tj@...nel.org, hannes@...xchg.org, shuah@...nel.org
Cc:     cgroups@...r.kernel.org, linux-kselftest@...r.kernel.org,
        linux-kernel@...r.kernel.org,
        linux-kernel-mentees@...ts.linuxfoundation.org
Subject: Re: [PATCH] selftests/cgroup: Fix awk usage in test_cpuset_prs.sh
 that may cause error

On 2023/9/26 20:18, Waiman Long wrote:
> On 9/25/23 15:38, Juntong Deng wrote:
>> According to the awk manual, the -e option does not need to be specified
>> in front of 'program' (unless you need to mix program-file).
>>
>> The redundant -e option can cause error when users use awk tools other
>> than gawk (for example, mawk does not support the -e option).
>>
>> Error Example:
>> awk: not an option: -e
>> Cgroup v2 mount point not found!
>>
>> Signed-off-by: Juntong Deng <juntong.deng@...look.com>
>> ---
>>   tools/testing/selftests/cgroup/test_cpuset_prs.sh | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/tools/testing/selftests/cgroup/test_cpuset_prs.sh 
>> b/tools/testing/selftests/cgroup/test_cpuset_prs.sh
>> index 4afb132e4e4f..6820653e8432 100755
>> --- a/tools/testing/selftests/cgroup/test_cpuset_prs.sh
>> +++ b/tools/testing/selftests/cgroup/test_cpuset_prs.sh
>> @@ -20,7 +20,7 @@ skip_test() {
>>   WAIT_INOTIFY=$(cd $(dirname $0); pwd)/wait_inotify
>>   # Find cgroup v2 mount point
>> -CGROUP2=$(mount -t cgroup2 | head -1 | awk -e '{print $3}')
>> +CGROUP2=$(mount -t cgroup2 | head -1 | awk '{print $3}')
>>   [[ -n "$CGROUP2" ]] || skip_test "Cgroup v2 mount point not found!"
>>   CPUS=$(lscpu | grep "^CPU(s):" | sed -e "s/.*:[[:space:]]*//")
> 
> Yes, the -e option is redundant. Thanks for catching that.
> 
> Acked-by: Waiman Long <longman@...hat.com>
> 

Hi Shuah, this patch has been acked but does not seem to have been
applied yet.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ