From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#70415: 30.0.50; [Cygwin] `lock-file' creates a symlink with funny name Date: Wed, 17 Apr 2024 15:21:18 +0300 Message-ID: <86zftsgoxt.fsf@gnu.org> References: <861q75juvy.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3219"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 70415@debbugs.gnu.org To: Katsumi Yamaoka Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Apr 17 14:22:07 2024 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 1rx4Ih-0000ar-Kp for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 17 Apr 2024 14:22:07 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rx4IS-0007Es-Pf; Wed, 17 Apr 2024 08:21:52 -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 1rx4IR-0007Ed-7m for bug-gnu-emacs@gnu.org; Wed, 17 Apr 2024 08:21:51 -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 1rx4IQ-0000eJ-VY for bug-gnu-emacs@gnu.org; Wed, 17 Apr 2024 08:21:50 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rx4Id-0002Ix-Jj for bug-gnu-emacs@gnu.org; Wed, 17 Apr 2024 08:22:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 17 Apr 2024 12:22:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70415 X-GNU-PR-Package: emacs Original-Received: via spool by 70415-submit@debbugs.gnu.org id=B70415.17133565178804 (code B ref 70415); Wed, 17 Apr 2024 12:22:03 +0000 Original-Received: (at 70415) by debbugs.gnu.org; 17 Apr 2024 12:21:57 +0000 Original-Received: from localhost ([127.0.0.1]:45991 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rx4IV-0002HY-MT for submit@debbugs.gnu.org; Wed, 17 Apr 2024 08:21:57 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:36066) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rx4IS-0002GU-TR for 70415@debbugs.gnu.org; Wed, 17 Apr 2024 08:21:53 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rx4IA-0000dl-Ey; Wed, 17 Apr 2024 08:21:34 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=Hi+8zelcbhaQ+tjosSe4VxVqMPhkTY5xBAogteeD3q8=; b=GQVtaNB0/fP4 SOOoVJAqnV7b5qITaBb4BuZHMFy0z5pr0xvW0ONYmYOiY67o56sPt9iS/E4sgr6cqUt5D/JHs0/x7 /kqJ2trDE+AhIHzaEq3ThVMjR8u0Q4zLlK9HkFG0SP0R6BCVnq7Cs1P8B5ptDhf4s7mb1o+Xbxe5Y OSJAc4YYmIsZeHJ84psDf5ohd878nrNClbbzRQanexMPAN9Z3C0Awb4PHYR2xi9DK/w/UIC3sSyBn ZN9z5MdsgYK0hhaR200fPo036F+qFV+ASfxcgt9X/kRwDU1uL530ARw0XJkAUztuPYl4EoQ1gSAAR vyYOVE7V1pbgwy9cN+VJiA==; In-Reply-To: (message from Katsumi Yamaoka on Wed, 17 Apr 2024 08:58:42 +0900) 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:283484 Archived-At: > Date: Wed, 17 Apr 2024 08:58:42 +0900 > From: Katsumi Yamaoka > Cc: 70415@debbugs.gnu.org > > On Tue, 16 Apr 2024 16:32:17 +0300, Eli Zaretskii wrote: > >> .#FILE -> username@hostname.1234:-11644473599 > >> For that case `(unlock-file "FILE")' issues this warning: > >> Warning (unlock-file): Unlocking file: Invalid argument, FILE, ignored > > > The part after the colon is the system boot time, and is used on all > > Posix hosts. > > Oh, I had never seen it until recently. Thanks. The question is: why it started appearing only recently? The code in filelock.c hasn't changed since last December, if not earlier, so if this started happening recently, it could only be because Gnulib's get_boot_time or its Cygwin implementation changed, such that it was previously returning zero whereas now it returns non-zero (which triggers the addition of the ":BOOT_TIME" part to the file name). > >>| commit 393f58c85aeb78f814866ccaad9ae7efd3fa6766 > >>| Author: Adam Porter > >>| Date: Fri Mar 8 23:43:14 2024 -0600 > > > This is extremely unlikely to have caused the problem. It is more > > likely that some change in Cygwin and/or in the Gnulib's boot-time > > module causes this now. > > Indeed. But the fact is that Emacs built with that revno adds > a colon and a negative number to a link name and the one built > with just before it does not. No problem on 29.3.50 and earlier, > either (i.e., not add a colon and numbers). Then please step with a debugger through the relevant code in filelock.c, before and after that change, and see why they are different. I cannot explain that, even after doing "git log -L" on all of filelock.c: the most recent change of the related code was in Aug 2023, AFAICT, which is a very far cry from Mar 2024. And even if we understand why you now get the ":BOOT_TIME" part, there's still the question why it cannot be unlinked, if Cygwin supports file names with a colon. Maybe it's because Emacs creates a symlink, and symlinks with such names are not supported by Cygwin?