[gnutls-devel] GnuTLS | psktool: encode username if it contains special character (!1345)

Read-only notification of GnuTLS library development activities gnutls-devel at lists.gnutls.org
Thu Oct 29 13:25:59 CET 2020




Sahana Prasad started a new discussion on tests/suite/mini-record-timing.c: https://gitlab.com/gnutls/gnutls/-/merge_requests/1345#note_438267621

> -		else
> -			fprintf(stderr, "Child died with status %d\n",
> -				WEXITSTATUS(status));
> +		/* This code must be async-signal-safe. */
> +		if (WIFSIGNALED(status)) {
> +			const char msg[] = "Child died with sigsegv\n";
> +			write(STDERR_FILENO, "Child died with sigsegv\n", sizeof(msg));
> +		} else {
> +			char buf[64] = { 0 };
> +			char *p;
> +
> +			p = stpcpy(buf, "Child died with status ");
> +
> +			status = WEXITSTATUS(status) & 0377;
> +			if (status > 100)
> +				*p++ = '0' + status / 100;

@dueno don't we need
status = status % 100
after this line?

-- 
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/1345#note_438267621
You're receiving this email because of your account on gitlab.com.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20201029/f18c1618/attachment-0001.html>


More information about the Gnutls-devel mailing list