Re: [PATCH v3 8/9] selftests/arm: Add ptrace_64 test

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

 



On Tue, Jun 25, 2024 at 05:54:07PM +0530, Dev Jain wrote:

> +static int do_child(void)
> +{
> +	if (ptrace(PTRACE_TRACEME, -1, NULL, NULL))
> +		ksft_exit_fail_perror("PTRACE_TRACEME");
> +
> +	/* SIGTRAP makes the child stop after exec; do_parent() resumes it */
> +	execv("trivial_32bit_program", NULL);
> +	return EXIT_SUCCESS;
> +}

We should check that the execv() worked, one thing that can go wrong is
partially installing the tests or trying to run the tests in a different
directory to the one where everything is installed.  I'd be inclined to
specify the path as ./ too to avoid surprises.

Attachment: signature.asc
Description: PGP signature


[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