From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#16133: 24.3; copy-file fails on chmod when copying to FAT filesystem Date: Sun, 22 Dec 2013 20:35:39 +0200 Message-ID: <83eh5491j8.fsf@gnu.org> References: <52B62BC3.4050508@cs.ucla.edu> <83ob498s3q.fsf@gnu.org> <52B66414.1090709@cs.ucla.edu> <83ioug97lu.fsf@gnu.org> <52B72356.7000103@cs.ucla.edu> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1387737428 14676 80.91.229.3 (22 Dec 2013 18:37:08 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 22 Dec 2013 18:37:08 +0000 (UTC) Cc: ran@lasgalen.net, 16133@debbugs.gnu.org To: Paul Eggert Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Dec 22 19:37:14 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Vuntq-0004wN-E7 for geb-bug-gnu-emacs@m.gmane.org; Sun, 22 Dec 2013 19:37:14 +0100 Original-Received: from localhost ([::1]:58875 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vuntq-0007D3-1v for geb-bug-gnu-emacs@m.gmane.org; Sun, 22 Dec 2013 13:37:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35966) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vuntj-0007Cx-0Q for bug-gnu-emacs@gnu.org; Sun, 22 Dec 2013 13:37:11 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vunte-0001VM-65 for bug-gnu-emacs@gnu.org; Sun, 22 Dec 2013 13:37:06 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:49046) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vunte-0001V8-2P for bug-gnu-emacs@gnu.org; Sun, 22 Dec 2013 13:37:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Vuntd-0004s9-Jc for bug-gnu-emacs@gnu.org; Sun, 22 Dec 2013 13:37:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 22 Dec 2013 18:37:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 16133 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: confirmed Original-Received: via spool by 16133-submit@debbugs.gnu.org id=B16133.138773737618655 (code B ref 16133); Sun, 22 Dec 2013 18:37:01 +0000 Original-Received: (at 16133) by debbugs.gnu.org; 22 Dec 2013 18:36:16 +0000 Original-Received: from localhost ([127.0.0.1]:34831 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Vunst-0004qo-Km for submit@debbugs.gnu.org; Sun, 22 Dec 2013 13:36:15 -0500 Original-Received: from mtaout20.012.net.il ([80.179.55.166]:63311) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Vunsq-0004qd-Ii for 16133@debbugs.gnu.org; Sun, 22 Dec 2013 13:36:13 -0500 Original-Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0MY800M000X5TS00@a-mtaout20.012.net.il> for 16133@debbugs.gnu.org; Sun, 22 Dec 2013 20:35:48 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MY800M880ZOR740@a-mtaout20.012.net.il>; Sun, 22 Dec 2013 20:35:48 +0200 (IST) In-reply-to: <52B72356.7000103@cs.ucla.edu> X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:82401 Archived-At: > Date: Sun, 22 Dec 2013 09:37:26 -0800 > From: Paul Eggert > CC: 16133@debbugs.gnu.org, ran@lasgalen.net > > Eli Zaretskii wrote: > > I was referring to the use case described here: > > > > http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16133#14 > > > > The 'cp' equivalent of that is when it is invoked to copy more than > > one file, or copy a directory. > > The use case described there does not involve merely copy-file; > it also involves some other function (org-mobile-push, I guess) > that uses copy-file to copy files one at a time, > and which gives up if one instance of copy-file fails. > > This is akin to a shell script that uses cp to > copy files one a time, and which aborts if cp fails. > Such a script would behave the same way that org-mobile-push > behaves now, if I'm understanding the bug report correctly. > > One fix would be to modify org-mobile-push to not throw an error > when copy-file fails, but instead to continue. Perhaps this is the > desired behavior, not only for fchmod failure, but for other copy-file > failures such as write error. In any case org-mobile-push could > ignore some or all errors, or report them at the end, or whatever > it likes. Sorry, I disagree: it is not the business of copy-file to decide when to interrupt its caller. It is only justified to do that when the error is fatal; this one isn't: the file was copied. copy-file is akin to a library function. A library function should never decide on its own when to call it quits, because a library function never has enough context to do TRT.