From nobody Fri Mar 17 11:26:49 2023 X-Original-To: bugs@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 4PdMKP6XjRz3yFV5 for ; Fri, 17 Mar 2023 11:26:49 +0000 (UTC) (envelope-from bugzilla-noreply@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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4PdMKP47L3z3NsC for ; Fri, 17 Mar 2023 11:26:49 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1679052409; 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: in-reply-to:in-reply-to:references:references; bh=lPlnpb16tNbHJZhdWqucgIUfhg63ZSN3sIE/TKu93ls=; b=MV8keu0HqErjEwpBv9dvZO2b1ZR+Q+zvYfXUmes2CPGvB2lG+efvLwE4Xx//mFtsr3cz6N xyque8DTXxgpAfr3SHSXK6FsVE9VQ8bjhTlYFDycMpIHrU+jcSgu4duDwDDWWPHkDiJg1d DHB7QGoQszmFFYRB5Nb+muelnM9kCROADhJr/0NgqQob44zAvEOJ7F6ri0custrWYV2Kd+ MEZGwXbwril4558W6QE1HUxzeKBZda2jB31ULC+m0M9GZhFgw0+KxAkdNX2KM/bB/8jMMt P/5YgCzLw8+95ig62CNtV76SqgAH2e6nWpjCa06FUa5mp6yo+ncbkgP0T/My9A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1679052409; a=rsa-sha256; cv=none; b=W4+L/o1dhBwhbRFw9FOdPhGzl+w76jNjf2mCvgOtqkuvo6KE0CZSiAmXKEO6bprXOeSrXO cFH8nIzu7CeOrUPChYZao8Ai4fENIK+aCfS4qWoLsqOKDLUroKeayvjNw4r8o8Ovrwy8Rr kunfxMkjPFBifcIMI0wTbJjYA4oRUwU0YgzI3hBoEt5CkrhQMqEhMcfhtq2O2uGOR8Da0x //EeHPUJNWKg4d7LP/yfy2/OjhxrxrayQyjXLo4c+aYTxmUHQXRDeBrQFoPhDkkL3bFnX1 lpdZhW1mraSdOlDJ4TjmVLrqCMk+NfUXjypXp77rs/aQk1HFJXjI8x3bKvZekQ== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (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 4PdMKP3BQPzNkG for ; Fri, 17 Mar 2023 11:26:49 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 32HBQncY097593 for ; Fri, 17 Mar 2023 11:26:49 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 32HBQn5t097592 for bugs@FreeBSD.org; Fri, 17 Mar 2023 11:26:49 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 270283] would like an even safer LIST_FOREACH_SAFE() Date: Fri, 17 Mar 2023 11:26:49 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: kib@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@freebsd.org MIME-Version: 1.0 X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D270283 Konstantin Belousov changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kib@FreeBSD.org --- Comment #1 from Konstantin Belousov --- In such situation, where you have a possibility of uncontrolled removal of = the list elements, usual approach is to put a marker element on the list. The marker should be not subject for removal by any regular operations. See e.g. MNT_VNODE_FOREACH* and vm_pageout.c (search for marker). --=20 You are receiving this mail because: You are the assignee for the bug.=