From nobody Sat Sep 07 01:48:03 2024 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 4X0wwN354kz5WSRL; Sat, 07 Sep 2024 01:48:04 +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 4X0wwN27wFz4kLt; Sat, 7 Sep 2024 01:48:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1725673684; 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=zYLBVCaf8xIDoOMpr2lNMvWzZQvfmpJ+hEDeKDWQLzY=; b=bxKfG3bbap6b5F38+oK7MjGIYDlIFXcwwrMZOJEhdSGX+0RZ1hdKc7r3avwGpUGgG/SASy JyRhaniuYNXeK+2ggdSz2u8a2qvVOfXkCH6tDBoOYgSowThQhMPZGKBOvp7PRX6L61HpQ0 AhGaDO8RHh+XwrW8hbS5B9RPjQkl0V3wX0Av6P5Qe6eFSM8vTPKuWiyhNE3XDec9n4B/QV 2ffmUp0QDyrYduLfNLVfevyZKb2RKLTcJ7StpZ/n87RPS7WuKvOj7V3o38i/cXQgUDQlJM rERygii9wFhGy94aciCqYlQyj7kmYSXgYw14xHKJ5vHsEW/hyJwwvmh+w6KqMQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1725673684; a=rsa-sha256; cv=none; b=uWU5Q9ahKr9kYY4GtQoSI5FPv4YXL9wLDgJOU250fJq2hOAUSsyzZ7vmVWnQkArV4io/yi YaUVRrwfloiODdx71nVHSLhfb0xjXj64TOUXakbdZRpKfpCs9OWsvpCJH7QSrbTd1Vy/dz WBhmJHrm7AwsbY7ZYcxQrEt5cMFwFrcxZ5xX1b5yH4B+zMuNu2f+pB5X0d0A7uzsE8jaVP /3ravIn5uwkK/Is653r2LAtvSyEcgyH3k+D6xgpOlMgUgfBTRRQD1w04CyA9GKCS/xgWya C+Cs2PxsAD0Hes9i+0J8i/z/1hJd9fFi2x6Ohdf4K1JS/p860Vh5vfHcvhQMjg== 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=1725673684; 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=zYLBVCaf8xIDoOMpr2lNMvWzZQvfmpJ+hEDeKDWQLzY=; b=ssCwq1le3Q6GHj/CAv8/oTFrpmwTUfma967Yy3lGdZU3i5K7zzwJhYatznXTr+ObdcwA0R 5GG6jBYPHpmpeWsFMPc3Hl3NafiLZFlLv8wi9NBlhW1WdCd4tmktqxjjNPzWqbf67Olg8Q YjEI2blEu/pTMj/UoYkLb4RE2G+mJRDPQ0noxKlEEh0YR13SvBzmBYc2wO3tgUhjm1/uXk n+KEL7ULa7C47XAwG9qZ8OdmucY3BYIbvNiS/hMkCx9MZXkbAi5QE3/LUTkmje7+zTMOGt JOnDgFsLeEfwZUDfn/PI540QaHJ/UrI9W9gt65JMtDJRfNzNFBbvgQKMwwI2nA== 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 4X0wwN02wrzGPd; Sat, 7 Sep 2024 01:48:04 +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 4871m33m041927; Sat, 7 Sep 2024 01:48:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4871m3Rp041924; Sat, 7 Sep 2024 01:48:03 GMT (envelope-from git) Date: Sat, 7 Sep 2024 01:48:03 GMT Message-Id: <202409070148.4871m3Rp041924@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Jessica Clarke Subject: git: 10e602164f02 - stable/14 - ee: Fix use of uninitialised pointer in ispell_op 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: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 10e602164f0281d5f5dfea9ebf2b29fba4a716bc Auto-Submitted: auto-generated The branch stable/14 has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=10e602164f0281d5f5dfea9ebf2b29fba4a716bc commit 10e602164f0281d5f5dfea9ebf2b29fba4a716bc Author: Jessica Clarke AuthorDate: 2024-06-02 22:53:09 +0000 Commit: Jessica Clarke CommitDate: 2024-09-07 00:01:06 +0000 ee: Fix use of uninitialised pointer in ispell_op This used to be name = mktemp followed by fd = open downstream, replacing upstream's crude PID-based sprintf, but in 1.4.7 this was changed upstream to this buggy code, which we then picked up in the 1.5.0 import. Presumably nobody's actually used ee's ispell function in the past 15 years; that or it's just ended up using junk file names as temporary files if name's happened to be a valid address to something that can be interpreted as a string. Reported by: Dapeng Gao Fixes: 96b676e99984 ("Update ee(1) in the base system to version 1.5.0.") MFC after: 1 week (cherry picked from commit 25a33bfe9ce2b55812201f475e9d3e64009b40dc) --- contrib/ee/ee.c | 1 + 1 file changed, 1 insertion(+) diff --git a/contrib/ee/ee.c b/contrib/ee/ee.c index 2f122981dbe7..a14f9c0ead13 100644 --- a/contrib/ee/ee.c +++ b/contrib/ee/ee.c @@ -4431,6 +4431,7 @@ ispell_op(void) } (void)sprintf(template, "/tmp/ee.XXXXXXXX"); fd = mkstemp(template); + name = template; if (fd < 0) { wmove(com_win, 0, 0); wprintw(com_win, create_file_fail_msg, name);