From nobody Sat Feb 12 11:40:05 2022 X-Original-To: dev-commits-src-main@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 5BC9B19551BE; Sat, 12 Feb 2022 11:40:05 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JwpSP250Jz3hhg; Sat, 12 Feb 2022 11:40:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1644666005; 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=iHptef+0GhwctSLP6FsRgLgWmIYg/6ClLO+1Ifmjqow=; b=fyYY4V4c4Z7Z3D6noqrwz9FlobjVPaitnalRoHmgIhYQCFWg4JjKrxKIvFhOAbLpoK5vhe NSms3tAOmSDmz7hB165vMy5YoTjWc5pGE2iZCqEgz7N3ftC33v27XJYv9sXFcEMQhsZ5g+ Ju0IORCmc+evP1PXgta1vO/aLAW0Ghw2I3lBWcRKRGJ/Runfqxy1J6Qtu+CahVZeCvS5ne EVmMXpC2kfE1Z+lg0Qt/FqR+R9wrr8q045SxrTcaoFzD/5O6hscQ5ndyBnYu1x17Eevxku O502r7DVVGJhJ6c7lz7nKY5tbInJkbVo5iKCFkI2yxzp+cV7waQ4EXFIzPxtKw== 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 2889926F70; Sat, 12 Feb 2022 11:40:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 21CBe56o029954; Sat, 12 Feb 2022 11:40:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 21CBe50j029950; Sat, 12 Feb 2022 11:40:05 GMT (envelope-from git) Date: Sat, 12 Feb 2022 11:40:05 GMT Message-Id: <202202121140.21CBe50j029950@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Wolfram Schneider Subject: git: 98839c40c74a - main - better unique file names List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wosch X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 98839c40c74aed19324962c365ebc2cb8520f91e Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1644666005; 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=iHptef+0GhwctSLP6FsRgLgWmIYg/6ClLO+1Ifmjqow=; b=R+Hq06hWFM5sF1zHTB9WI4xM+vOINpIrXvHITa4sPHk7wJdBVmduYaEFGKqb+7PTiV/7Nc 9Fh2JC7xzqohXmxkA4t+Ib3hkws7hw5TqnJI1sfJN7BSFlUbGhKocZ152WmYHnQ7dUzwtC WO4PaSZr/3TvqoBBC182RlgJnAhqAuEmJH6/K+a9jegffsb0m6UtuHFjmpTRNFSD5+3Amf SEm5dDx1n+eXQ+AZhwDRx+iqNGu3bBN6mPgB0yW1ZuwSjLw1GO+01kKHNNe5DSky4njJJk MMbVGBPWUrEo2IvjOp5QN9eogVxLc/+wMkYYak9P1lUoNOlDufekMKgZZA3e0A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1644666005; a=rsa-sha256; cv=none; b=VwkLeykzFSHJR7eyHcnfwu52+rhnAVUR7gVWoNc3+IRlfsd5rOiQD3/M10OZjj0Anza7GG 4e2dTK37rI5V387/3yHnNYsLmUOCFFX5gQubTIrspaMayhJs5hZ5zqDWA7I/B4AX8MHoMV waBqvHv8Kcnka5quJeGFSL/pT3gwyD5nzxmII4HJrKG2+7Uns/XwXlWa4qG4jCPMZBxkr5 Z2OrVEZ25wXCnMkLfhDhqsYD5jlAcFJQYa/asXBn0wll4rA3rV6qAL6WdgU9DqisykHYiD o+OcdIpZ6rXzZ0HdSswk1cMV1v/P+uXNMylrxk9VYiEiXoXGRXGxWl69Em777Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by wosch: URL: https://cgit.FreeBSD.org/src/commit/?id=98839c40c74aed19324962c365ebc2cb8520f91e commit 98839c40c74aed19324962c365ebc2cb8520f91e Author: Wolfram Schneider AuthorDate: 2022-02-12 11:35:51 +0000 Commit: Wolfram Schneider CommitDate: 2022-02-12 11:35:51 +0000 better unique file names Our mktemp(1) implementation uses 8-X for a temp file by default. That's ok, but we should increase the value from 8 to 10 as many other OS already did. PR: 261438 --- usr.bin/mktemp/mktemp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.bin/mktemp/mktemp.c b/usr.bin/mktemp/mktemp.c index 0b320e8c5c85..754cc8da7e4e 100644 --- a/usr.bin/mktemp/mktemp.c +++ b/usr.bin/mktemp/mktemp.c @@ -97,9 +97,9 @@ main(int argc, char **argv) if (tflag) { tmpdir = getenv("TMPDIR"); if (tmpdir == NULL) - asprintf(&name, "%s%s.XXXXXXXX", _PATH_TMP, prefix); + asprintf(&name, "%s%s.XXXXXXXXXX", _PATH_TMP, prefix); else - asprintf(&name, "%s/%s.XXXXXXXX", tmpdir, prefix); + asprintf(&name, "%s/%s.XXXXXXXXXX", tmpdir, prefix); /* if this fails, the program is in big trouble already */ if (name == NULL) { if (qflag)