From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Andreas Politz Newsgroups: gmane.emacs.bugs Subject: bug#26126: 26.0.50; file-notify-rm-watch removes arbitrary watches Date: Fri, 17 Mar 2017 18:45:49 +0100 Message-ID: <87tw6rssoi.fsf@luca> References: <87r31x9ulw.fsf@luca> <87shmcney8.fsf@detlef> <87efxw7xvc.fsf@luca> <87mvcjophx.fsf@detlef> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1489772837 20585 195.159.176.226 (17 Mar 2017 17:47:17 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 17 Mar 2017 17:47:17 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) Cc: 26126@debbugs.gnu.org To: Michael Albinus Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Mar 17 18:47:13 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 1covy1-0004Vu-9C for geb-bug-gnu-emacs@m.gmane.org; Fri, 17 Mar 2017 18:47:09 +0100 Original-Received: from localhost ([::1]:50143 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1covy7-0002uk-Ae for geb-bug-gnu-emacs@m.gmane.org; Fri, 17 Mar 2017 13:47:15 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42918) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1covxz-0002tZ-B1 for bug-gnu-emacs@gnu.org; Fri, 17 Mar 2017 13:47:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1covxu-0001eT-G3 for bug-gnu-emacs@gnu.org; Fri, 17 Mar 2017 13:47:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:34645) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1covxu-0001eL-4J for bug-gnu-emacs@gnu.org; Fri, 17 Mar 2017 13:47:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1covxt-0005AG-RU for bug-gnu-emacs@gnu.org; Fri, 17 Mar 2017 13:47:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Andreas Politz Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 17 Mar 2017 17:47:01 +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.148977277119771 (code B ref 26126); Fri, 17 Mar 2017 17:47:01 +0000 Original-Received: (at 26126) by debbugs.gnu.org; 17 Mar 2017 17:46:11 +0000 Original-Received: from localhost ([127.0.0.1]:32844 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1covx5-00058o-D0 for submit@debbugs.gnu.org; Fri, 17 Mar 2017 13:46:11 -0400 Original-Received: from gateway-a.fh-trier.de ([143.93.54.181]:58973) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1covx3-00058W-JK for 26126@debbugs.gnu.org; Fri, 17 Mar 2017 13:46:10 -0400 X-Virus-Scanned: by Amavisd-new + McAfee uvscan + ClamAV [Rechenzentrum Hochschule Trier (RZ/HT)] Original-Received: from localhost (ip5f5bdecf.dynamic.kabel-deutschland.de [95.91.222.207]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: politza) by gateway-a.fh-trier.de (Postfix) with ESMTPSA id A2782179AA60; Fri, 17 Mar 2017 18:45:49 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha1; c=simple/simple; d=hochschule-trier.de; s=default; t=1489772749; bh=HXgZGZnvIy0p4bUvCtRMfiMVLbs=; h=From:To:Cc:Subject:References:Date:In-Reply-To:Message-ID: MIME-Version:Content-Type; b=Ova3IEK+ZQEPLXOZWV3BmVAi7AOyoLx3xMtwARz4DWv56ZsQBY1Pd/JDzbjjGX0eK FEUj8/cr4FXorQQ1MKn1KCpXGFBxxjqbK2k+fu4X74GNXH9hDbGH6SJrOAkah4CH2W M4XDnwahL/fnfOtXxVVhz0PaOJ3W6sVuKsgPJFn4= In-Reply-To: <87mvcjophx.fsf@detlef> (Michael Albinus's message of "Fri, 17 Mar 2017 17:08:10 +0100") 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:130679 Archived-At: Michael Albinus writes: > I need to dig into inotify.c. IIRC, it wasn't simple to achieve this; > that's why we have this crude solution. Maybe it could be solved only on > filenotify.el level, don't remember the details. What I would do, is box the internal descriptor in file-notify-add-watch, to make it unique to the caller and unbox it in file-notify-rm-watch and file-notify-valid-p. A different question is, whether file-notify-add-watch should behave like add-hook with regards to adding a function multiple times. I don't think it does at the moment, so I probably leave it as such (?). -ap