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] [thread-next>] [day] [month] [year] [list]
Message-ID: <cfc06689-70a6-45e0-aab7-424da468f8c9@arm.com>
Date: Wed, 26 Jun 2024 19:06:50 +0530
From: Dev Jain <dev.jain@....com>
To: Oleg Nesterov <oleg@...hat.com>
Cc: shuah@...nel.org, mingo@...nel.org, tglx@...utronix.de,
 mark.rutland@....com, ryan.roberts@....com, broonie@...nel.org,
 suzuki.poulose@....com, Anshuman.Khandual@....com,
 DeepakKumar.Mishra@....com, aneesh.kumar@...nel.org,
 linux-kselftest@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3 2/2] selftests: Add a test mangling with uc_sigmask


On 6/26/24 17:24, Oleg Nesterov wrote:
> On 06/26, Dev Jain wrote:
>> +int main(int argc, char *argv[])
>> +{
>> +	struct sigaction act, act2;
>> +	sigset_t *set, *oldset;
> ...
>
>> +	set = malloc(sizeof(sigset_t *));
>> +	if (!set)
>> +		ksft_exit_fail_perror("malloc");
>> +
>> +	oldset = malloc(sizeof(sigset_t *));
> Why malloc() ?
>
> Can't you simply do
>
> 	sigset_t set, oldset;
>
> and then use sigemptyset(&set) / etc ?
>
> Oleg.


Ah yes, let us allocate it on the stack. I shall change it.

>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ