From nobody Sat Jan 04 03:57:44 2025 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4YQ6951tFKz5j8mh; Sat, 04 Jan 2025 03:57:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4YQ6951KJCz4qM3; Sat, 4 Jan 2025 03:57:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1735963065; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GGQ71WyCywzCcyglgz0yJCOUTw4aZeE5xXs9b7oyT4E=; b=rzJfI6rGhvBipRkcRQtWpRfLbutGzjxiqmRa6O+I1Qx9hF5YJ2brTgNC07VZE9MGzplSRp jNLOXqQXEB8/Mx3MRdnxrW2KbFDM3fbBFwDsvXAltn56uztB7F91ayopMEtZHiRoJTw3CF qtj/72bkZ7LE9AUkU+PMQnTwWIXao9T/etk3SAY5X19jNXZ1d5aeU63oShedx/P5gbXhN5 cEduYI8MJNuiTfQ4qMmhesarvMkWqxCSd31tCwa5No/Qhfhg30CKK7wnBatHaEYX2YwGh6 SuTnhNuBbsKq9aF+4HRdfcPPWMne/9VZTWcUeoUvXH0fPLFFGZng2piRwDQhWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1735963065; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GGQ71WyCywzCcyglgz0yJCOUTw4aZeE5xXs9b7oyT4E=; b=OeZXPGqpz4HEKjcliYR5f+0X+PXogyZKNAWV67fCkjRl8cjb2eh/YHxi19D4i6LtDdenQu R64CEEbpfpkKtYV1DKQGW344YDMY3VqK8g017U3GjZqFHo1THMImM8ozz9F2NW19P8DGzt QgN6G5IGOERHsML1QBnCn/b4CeNX118xQWO0M9Iue5jm54b1c5WWoVdrRSk+9pjbuiuPEI /slc2d1Xvye7VidQ4asD4FlSryvhHaKdBCQmG0zuo2BZB2CbnImucEWGNKNIZ94VFDTR+P x4NHDQpxinUX06K2mmHtaFy+DDaZ/PUdXrgDFXe++KpCL12xSMJVyJARUSHGYA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1735963065; a=rsa-sha256; cv=none; b=X7w8fr0C8jQPQbAb33VjH4DC6sP87Zrs2eH4hxN/WEnYA0MyIyzArwzpHdXV2iMKzI6GPK V62920geza2lf/WEG7SG6gwthUTEX9NL8LBJ8r5py/9dv+JfqKGeyGTbU5j0g7CQFk4zK6 sL7o1YsEIeYmSxaR1LsSGjvT7Zvf7a/ER0qyrlRolQdpmbOKH2kxaX/rTjlR2Wzpg4MPFp zWTZKyW4lpPFhCCBCgbWQ182Rbw1cTWLbbpeanA7XGCOCdPqLpXO3mSN7Y+t398LejwMIp DdGieDQeXDzULGEFvVYN9rhGZRjQV+7Kaf6P9C01ZMz53iMUrlWt1UtKakp4Aw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4YQ6950PF9zcpn; Sat, 04 Jan 2025 03:57:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 5043vib7028225; Sat, 4 Jan 2025 03:57:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 5043vidY028222; Sat, 4 Jan 2025 03:57:44 GMT (envelope-from git) Date: Sat, 4 Jan 2025 03:57:44 GMT Message-Id: <202501040357.5043vidY028222@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 06a8084a147f - stable/14 - thr_sig.c: style List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 06a8084a147f67460b0d1eb32a7d6dc420263ba0 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=06a8084a147f67460b0d1eb32a7d6dc420263ba0 commit 06a8084a147f67460b0d1eb32a7d6dc420263ba0 Author: Konstantin Belousov AuthorDate: 2024-12-22 20:35:26 +0000 Commit: Konstantin Belousov CommitDate: 2025-01-04 03:57:24 +0000 thr_sig.c: style (cherry picked from commit e32308efa215868d98036c30f73c98ebf67e03d4) --- lib/libthr/thread/thr_sig.c | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/lib/libthr/thread/thr_sig.c b/lib/libthr/thread/thr_sig.c index ad291d106001..a8268f2a770d 100644 --- a/lib/libthr/thread/thr_sig.c +++ b/lib/libthr/thread/thr_sig.c @@ -185,8 +185,7 @@ thr_remove_thr_signals(const sigset_t *set, sigset_t *newset) } static void -sigcancel_handler(int sig __unused, - siginfo_t *info __unused, ucontext_t *ucp) +sigcancel_handler(int sig __unused, siginfo_t *info __unused, ucontext_t *ucp) { struct pthread *curthread = _get_curthread(); int err; @@ -357,7 +356,7 @@ check_cancel(struct pthread *curthread, ucontext_t *ucp) * on getting a signal before it agrees to return. */ if (curthread->cancel_point) { - if (curthread->in_sigsuspend && ucp) { + if (curthread->in_sigsuspend && ucp != NULL) { SIGADDSET(ucp->uc_sigmask, SIGCANCEL); curthread->unblock_sigcancel = 1; _thr_send_sig(curthread, SIGCANCEL); @@ -368,8 +367,8 @@ check_cancel(struct pthread *curthread, ucontext_t *ucp) * asynchronous cancellation mode, act upon * immediately. */ - _pthread_exit_mask(PTHREAD_CANCELED, - ucp? &ucp->uc_sigmask : NULL); + _pthread_exit_mask(PTHREAD_CANCELED, ucp != NULL ? + &ucp->uc_sigmask : NULL); } } @@ -407,9 +406,8 @@ check_suspend(struct pthread *curthread) { uint32_t cycle; - if (__predict_true((curthread->flags & - (THR_FLAGS_NEED_SUSPEND | THR_FLAGS_SUSPENDED)) - != THR_FLAGS_NEED_SUSPEND)) + if (__predict_true((curthread->flags & (THR_FLAGS_NEED_SUSPEND | + THR_FLAGS_SUSPENDED)) != THR_FLAGS_NEED_SUSPEND)) return; if (curthread == _single_thread) return; @@ -666,7 +664,7 @@ _thr_sigmask(int how, const sigset_t *set, sigset_t *oset) } int -_sigsuspend(const sigset_t * set) +_sigsuspend(const sigset_t *set) { sigset_t newset; @@ -674,7 +672,7 @@ _sigsuspend(const sigset_t * set) } int -__thr_sigsuspend(const sigset_t * set) +__thr_sigsuspend(const sigset_t *set) { struct pthread *curthread; sigset_t newset; @@ -700,7 +698,7 @@ __thr_sigsuspend(const sigset_t * set) int _sigtimedwait(const sigset_t *set, siginfo_t *info, - const struct timespec * timeout) + const struct timespec *timeout) { sigset_t newset; @@ -715,7 +713,7 @@ _sigtimedwait(const sigset_t *set, siginfo_t *info, */ int __thr_sigtimedwait(const sigset_t *set, siginfo_t *info, - const struct timespec * timeout) + const struct timespec *timeout) { struct pthread *curthread = _get_curthread(); sigset_t newset;