From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Michael Albinus Newsgroups: gmane.emacs.bugs Subject: bug#26126: 26.0.50; file-notify-rm-watch removes arbitrary watches Date: Sat, 18 Mar 2017 20:49:22 +0100 Message-ID: <87shmagybh.fsf@detlef> References: <87r31x9ulw.fsf@luca> <87shmcney8.fsf@detlef> <87efxw7xvc.fsf@luca> <87mvcjophx.fsf@detlef> <87tw6rssoi.fsf@luca> <87pohfkmvh.fsf@detlef> <87d1de1j1t.fsf@luca> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1489866612 5115 195.159.176.226 (18 Mar 2017 19:50:12 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 18 Mar 2017 19:50:12 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) Cc: 26126@debbugs.gnu.org To: Andreas Politz Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Mar 18 20:50:08 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cpKMZ-0000cU-2E for geb-bug-gnu-emacs@m.gmane.org; Sat, 18 Mar 2017 20:50:07 +0100 Original-Received: from localhost ([::1]:54532 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cpKMd-0005rN-Hw for geb-bug-gnu-emacs@m.gmane.org; Sat, 18 Mar 2017 15:50:11 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52945) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cpKMY-0005pv-0P for bug-gnu-emacs@gnu.org; Sat, 18 Mar 2017 15:50:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cpKMU-0006mM-To for bug-gnu-emacs@gnu.org; Sat, 18 Mar 2017 15:50:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:36137) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cpKMU-0006lY-QG for bug-gnu-emacs@gnu.org; Sat, 18 Mar 2017 15:50:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cpKMU-0008C3-Bf for bug-gnu-emacs@gnu.org; Sat, 18 Mar 2017 15:50:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 18 Mar 2017 19:50:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 26126 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 26126-submit@debbugs.gnu.org id=B26126.148986657431455 (code B ref 26126); Sat, 18 Mar 2017 19:50:02 +0000 Original-Received: (at 26126) by debbugs.gnu.org; 18 Mar 2017 19:49:34 +0000 Original-Received: from localhost ([127.0.0.1]:34336 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cpKM2-0008BG-IH for submit@debbugs.gnu.org; Sat, 18 Mar 2017 15:49:34 -0400 Original-Received: from mout.gmx.net ([212.227.15.15]:57824) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cpKM0-0008B3-H7 for 26126@debbugs.gnu.org; Sat, 18 Mar 2017 15:49:33 -0400 Original-Received: from detlef.gmx.de ([87.146.40.245]) by mail.gmx.com (mrgmx002 [212.227.17.190]) with ESMTPSA (Nemesis) id 0MBnvD-1cxKRX0ngt-00Amgy; Sat, 18 Mar 2017 20:49:24 +0100 In-Reply-To: <87d1de1j1t.fsf@luca> (Andreas Politz's message of "Sat, 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83PFVGjFrauXbr1COuaCJSJAJqkpfF/MCoI+N8zNHfBT3ybi85j1FViXP X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:130716 Archived-At: Andreas Politz writes: Hi Andreas, > Do you remember what this comment from file-notify-callback is talking > about ? > > #+BEGIN_SRC emacs-lisp > ((memq action '(moved rename)) > ;; The kqueue rename event does not return file1 in > ;; case a file monitor is established. > (if (setq file1 (file-notify--event-file1-name event)) > 'renamed 'deleted)) > #+END_SRC kqueue is the oldest of he supported native libraries. It is the only one (IIRC), which does not return source and target file name in case of a rename. That's why that the kqueue `rename' event is transformed into a `deleted' event. This is what the comment is speaking about. I admit it would be more understandable if there would be an overview of the events and their arguments, the different libraries are sending. > And file-notify--event-file1-name basically returns nil, if the file1 > argument of event is not a string. But this seems to contradict the > comment, which states that file1 *is* nil, implying that the stored > filename should be used, or not ? The fourth slot of an event structure could be either a string (file1) or a cookie, or nil. This is tried to check. > -ap Best regards, Michael.