From nobody Fri Sep 20 14:38:27 2024 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 4X9FPJ0xxYz5XPpc for ; Fri, 20 Sep 2024 14:38:28 +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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4X9FPH70CPz4K4n for ; Fri, 20 Sep 2024 14:38:27 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1726843108; a=rsa-sha256; cv=none; b=bqVoWsSEz6mQrW8oW6JRNBjEBW+zeekqYCcr1XPL6arN/zx2tAw7ycDibmdzb+ZqsF4ItW tH95dBpEaXMoAIneVsyHkfbrEc/VqEL1dr7xLq+Z9PpaJPxHZ4JY0co7u95qKgBexKDXVV wGXxBOEq4dGiMo8pOQqc9juebVNISuGBlBsVvx9D7vPvun76u1Z2Xu2nLGyXbjIso4NdTY nmlQFEdEasVh2zlBJ2L17y5eifPXR3IGRnEpHYoQaKMbGLioenzduc9U5RKWWr+0QUznyp 7xx94/PL2FIhrnmDiWKphFVYhkhk8yTPQwwvM+XBjaC+Pub1QqCm+xnv09h/9w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1726843108; 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=YmZU51A095zfceSVdVxec1LT2N1+teLyIIooFZLufFs=; b=jZ/GaZMnonCNRcMv6Siukyxi0hVEDmxV+Bz7uXzx5dox2SqCRqCA0ykJYExutd1J5jjWdO DZ0F9m7L3wTrQxT5z8NW6ghuuEICc+V7G+QIxkh2g7JZZV2GEaFqHjnuegV8rMHsQf+fVo +TEez9hi3T1FVXTpbPLpYWhNIhH9lLRnrIWS3vtEVJ4OycWX78br3IGmh3JAwXU4R9Pupe ZnOZAiLhKBdWej1SRBDYSDsW4+il0mpHm/UJSoO3PWGJAPPTZpOYt8Gw0+PDkIyJUULToW sE71UyRns/UzsyrIx+EFIGOP+b2zo/e1asxlJblG4CJWQ71t3eeUjK7RvDB6mw== 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 4X9FPH6Y82ztLg for ; Fri, 20 Sep 2024 14:38:27 +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 48KEcRQ3020664 for ; Fri, 20 Sep 2024 14:38:27 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 48KEcRxl020663 for bugs@FreeBSD.org; Fri, 20 Sep 2024 14:38:27 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 281483] [librt] timer_delete segfaults with incorrect timer id Date: Fri, 20 Sep 2024 14:38:27 +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: 14.1-RELEASE X-Bugzilla-Keywords: crash X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: jhb@FreeBSD.org X-Bugzilla-Status: Closed X-Bugzilla-Resolution: Works As Intended X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: resolution bug_status 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 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D281483 John Baldwin changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |Works As Intended Status|New |Closed CC| |jhb@FreeBSD.org --- Comment #1 from John Baldwin --- Hardcoding 0 as an argument to timer_delete() is undefined behavior. From https://pubs.opengroup.org/onlinepubs/9799919799/functions/timer_delete.htm= l: The behavior is undefined if the value specified by the timerid argument to timer_delete() does not correspond to a timer ID returned by timer_create()= but not yet deleted by timer_delete(). It is true that later in the same page, it recommends returning EINVAL if a= bad timer_t value is detected, but we cannot reliably detect double free which would be the more common error. Hardcoding a constant 0 is not portable. --=20 You are receiving this mail because: You are the assignee for the bug.=