Re: [PATCH v3 2/2] selftests: Add a test mangling with uc_sigmask

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

 



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.





[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux