From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Newsgroups: gmane.emacs.bugs Subject: bug#64821: 30.0.50; write-region errs when overwriting an already open file Date: Thu, 27 Jul 2023 17:07:26 +0200 Message-ID: <2B783248-53AF-4486-8208-74A6B0A517EE@gmail.com> References: <87y1j53hrz.fsf@localhost> Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.120.0.1.15\)) Content-Type: multipart/mixed; boundary="Apple-Mail=_63B30E48-5A58-487D-8461-CE7F3933A430" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="2596"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 64821@debbugs.gnu.org, Ihor Radchenko To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Jul 27 17:19:11 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qP2li-0000ST-R7 for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 27 Jul 2023 17:19:10 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qP2ay-0001KH-Ca; Thu, 27 Jul 2023 11:08:04 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qP2ax-0001K8-2w for bug-gnu-emacs@gnu.org; Thu, 27 Jul 2023 11:08:03 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qP2aw-0000t0-Rm for bug-gnu-emacs@gnu.org; Thu, 27 Jul 2023 11:08:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qP2aw-00074L-0s for bug-gnu-emacs@gnu.org; Thu, 27 Jul 2023 11:08:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <87y1j53hrz.fsf@localhost> Resent-From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 27 Jul 2023 15:08:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64821 X-GNU-PR-Package: emacs Original-Received: via spool by 64821-submit@debbugs.gnu.org id=B64821.169047045827139 (code B ref 64821); Thu, 27 Jul 2023 15:08:01 +0000 Original-Received: (at 64821) by debbugs.gnu.org; 27 Jul 2023 15:07:38 +0000 Original-Received: from localhost ([127.0.0.1]:42878 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qP2aY-00073f-2q for submit@debbugs.gnu.org; Thu, 27 Jul 2023 11:07:38 -0400 Original-Received: from mail-lf1-x12b.google.com ([2a00:1450:4864:20::12b]:53539) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qP2aU-00073M-7x for 64821@debbugs.gnu.org; Thu, 27 Jul 2023 11:07:37 -0400 Original-Received: by mail-lf1-x12b.google.com with SMTP id 2adb3069b0e04-4fba8f2197bso1785359e87.3 for <64821@debbugs.gnu.org>; Thu, 27 Jul 2023 08:07:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1690470448; x=1691075248; h=to:cc:date:message-id:subject:mime-version:from:sender:from:to:cc :subject:date:message-id:reply-to; bh=QfYhx9nwxMGjhiHpZuolL+5AD1YLAGVheOq++9FNCik=; b=HZyh9TzttWeYXAJzkk4eocFh0PouFIRGpiRPN1O3+lmDgcNk78y/gRwhyybne93+++ exHX7G339fY98H5OJGRremGYfVA5Plt2Vmwswz5qcNsKRdCUnQYxflbItmiXnLh2qzys KBVD9mrGHQtqjEMN2UWty+g6Eh9R7xeyQOSmtPGUH2JHr/fR/wRNgrRQ2P90Aou/cPxg kC+pK3zdlR++Jr8du1gVCh3YhzkgUyNjJmHeKcc90YLcwXpl5s9w/58PU7776BzEj/oI 7eJ+iGyWQAcUM4IssKXM7RvPsZ+KbpOo43RUbHaLuVk4feVo+ssRw080nRP9vNEbNFjb ssSA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690470448; x=1691075248; h=to:cc:date:message-id:subject:mime-version:from:sender :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=QfYhx9nwxMGjhiHpZuolL+5AD1YLAGVheOq++9FNCik=; b=Ud28Eu6pqnGjN6e3LZOgEJvaUGqN2l53ogPATmUH2qR/ZA9qH+HaELbYRtOE3s8IQD 8G7OLMw7MGi4pomLsDLL4CPGpplroxWPqctavMtMA1bEMrWiQj1pQ/TyNnMndaccpDs2 GZjJOPUJsaBeyfKRfWIGzo1caPW+htUyNGW7HAaRIHuw857cZTONCMasOa7Z1rbryA/Q OSdCJYgLOD1KhuHTNb4c0EeNrSIiv6WXjSJUZRYRwQ6g4G8c0+M7QqHuYc9v8Z5OBozN PwwCQufrzi59NlOiwIS/vT6GTGPGBY1sXSnBCuV3aF3i6o5yObZUv73qaI1RgTwGCTfT 6ydw== X-Gm-Message-State: ABy/qLZsQBMnzfE3+yc5rKwTbyT5bHe0UFhKu+6QjrIfj7lFnhgkxikd p9jqJ5b+Cx1LCDaMIg2sehSpnfQNOis= X-Google-Smtp-Source: APBJJlHh+lanRXD5w2YVhTovTpfqb3bvbigSeRkMN3g7X1mjhpSGHDjGdhNQY5enFFnoowC2dAGLtA== X-Received: by 2002:a05:6512:2354:b0:4fb:7642:88dd with SMTP id p20-20020a056512235400b004fb764288ddmr2001734lfu.67.1690470448228; Thu, 27 Jul 2023 08:07:28 -0700 (PDT) Original-Received: from smtpclient.apple (c188-150-165-235.bredband.tele2.se. [188.150.165.235]) by smtp.gmail.com with ESMTPSA id n21-20020a195515000000b004fad5602c18sm351673lfe.73.2023.07.27.08.07.27 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 27 Jul 2023 08:07:27 -0700 (PDT) X-Mailer: Apple Mail (2.3654.120.0.1.15) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:266198 Archived-At: --Apple-Mail=_63B30E48-5A58-487D-8461-CE7F3933A430 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii The change on master (8955853368) causes filelock-tests to fail; see = attached log. This is on macOS with an out-of-tree build. --Apple-Mail=_63B30E48-5A58-487D-8461-CE7F3933A430 Content-Disposition: attachment; filename=filelock-tests.log Content-Type: application/octet-stream; x-unix-mode=0644; name="filelock-tests.log" Content-Transfer-Encoding: 7bit GEN src/filelock-tests.log Running 6 tests (2023-07-27 17:03:57+0200, selector `(not (or (tag :unstable) (tag :nativecomp)))') (Shell command succeeded with no output) Test filelock-tests-detect-external-change backtrace: userlock--check-content-unchanged("/private/var/folders/qy/zstv16390 userlock--ask-user-about-supersession-threat("/private/var/folders/q insert("bar") (let ((create-lockfiles cl)) (write-region "foo" nil (buffer-file-na (save-current-buffer (let ((create-lockfiles cl)) (write-region "foo (unwind-protect (save-current-buffer (let ((create-lockfiles cl)) (w (progn (progn (setq buffer-file-name name) (setq buffer-file-truenam (unwind-protect (progn (progn (setq buffer-file-name name) (setq buf (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current (let ((name (concat (file-name-as-directory temp-dir) "userfile")) ( (progn (let ((name (concat (file-name-as-directory temp-dir) "userfi (unwind-protect (progn (let ((name (concat (file-name-as-directory t (let* ((coding-system-for-write nil) (temp-file (file-name-as-direct (let ((cl (car tail))) (let* ((coding-system-for-write nil) (temp-fi (while tail (let ((cl (car tail))) (let* ((coding-system-for-write n (let ((tail '(t nil))) (while tail (let ((cl (car tail))) (let* ((co (closure (t) nil (let* ((fn-101 #'not) (args-102 (condition-case err ert--run-test-internal(#s(ert--test-execution-info :test #s(ert-test ert-run-test(#s(ert-test :name filelock-tests-detect-external-change ert-run-or-rerun-test(#s(ert--stats :selector (not ...) :tests [... ert-run-tests((not (or (tag :unstable) (tag :nativecomp))) #f(compil ert-run-tests-batch((not (or (tag :unstable) (tag :nativecomp)))) ert-run-tests-batch-and-exit((not (or (tag :unstable) (tag :nativeco eval((ert-run-tests-batch-and-exit '(not (or (tag :unstable) (tag :n command-line-1(("-L" ":../../emacs/test" "-l" "ert" "-l" "src/filelo command-line() normal-top-level() Test filelock-tests-detect-external-change condition: (wrong-type-argument stringp nil) FAILED 1/6 filelock-tests-detect-external-change (0.024295 sec) at ../../emacs/test/src/filelock-tests.el:173 passed 2/6 filelock-tests-file-locked-p-spoiled (0.001322 sec) passed 3/6 filelock-tests-kill-buffer-spoiled (0.000714 sec) passed 4/6 filelock-tests-lock-spoiled (0.000609 sec) passed 5/6 filelock-tests-lock-unlock-no-errors (0.001055 sec) passed 6/6 filelock-tests-unlock-spoiled (0.000917 sec) Ran 6 tests, 5 results as expected, 1 unexpected (2023-07-27 17:03:58+0200, 0.274700 sec) 1 unexpected results: FAILED filelock-tests-detect-external-change --Apple-Mail=_63B30E48-5A58-487D-8461-CE7F3933A430 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii --Apple-Mail=_63B30E48-5A58-487D-8461-CE7F3933A430--