From unknown Mon Aug 18 09:03:03 2025 X-Loop: help-debbugs@gnu.org Subject: bug#29362: 27.0.50; copy-file no longer copying when second argument is a directory Resent-From: kramer@cogeco.ca (Bryan M. Kramer) Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 Nov 2017 21:09:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 29362 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 29362@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.15111256898331 (code B ref -1); Sun, 19 Nov 2017 21:09:02 +0000 Received: (at submit) by debbugs.gnu.org; 19 Nov 2017 21:08:09 +0000 Received: from localhost ([127.0.0.1]:47986 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eGWoy-0002AI-Oj for submit@debbugs.gnu.org; Sun, 19 Nov 2017 16:08:09 -0500 Received: from eggs.gnu.org ([208.118.235.92]:56912) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eGWow-00029r-OA for submit@debbugs.gnu.org; Sun, 19 Nov 2017 16:08:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eGWoq-0003SW-7J for submit@debbugs.gnu.org; Sun, 19 Nov 2017 16:08:01 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:35617) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eGWoq-0003SS-3X for submit@debbugs.gnu.org; Sun, 19 Nov 2017 16:08:00 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47873) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eGWoo-0004MM-PQ for bug-gnu-emacs@gnu.org; Sun, 19 Nov 2017 16:07:59 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eGWol-0003Q1-Jx for bug-gnu-emacs@gnu.org; Sun, 19 Nov 2017 16:07:58 -0500 Received: from smtp.cogeco.net ([216.221.81.25]:5897 helo=fipsb02.cogeco.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eGWol-0003P9-E8 for bug-gnu-emacs@gnu.org; Sun, 19 Nov 2017 16:07:55 -0500 X-Cloudmark-SP-Filtered: true X-Cloudmark-SP-Result: v=2.1 cv=Z+dMZClA c=1 sm=2 tr=0 a=4y8eiijtOmm9PFOCF9AQnw==:17 a=sC3jslCIGhcA:10 a=t3gNw3sAgXgBy2c-dX8A:9 a=7Zwj6sZBwVKJAoWSPKxL6X1jA+E=:19 a=vUQH2Om9SdEo_yeO:21 a=HwnxQMBBdtmaNZ7s:21 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A2BQBwBj8RFa/wq1lhhbH4MgLkYgbo85jjUBhHmVdoU/BIRqRBQBAQEBAQEBAQFrKIV7EwFLDwQhASlVigesAIslgzSNawEBCGSFCiAFkXSBFI82qFiXbDYigXSBWIJlggsMQQQbggUjiWwWgiIBAQE X-IPAS-Result: A2BQBwBj8RFa/wq1lhhbH4MgLkYgbo85jjUBhHmVdoU/BIRqRBQBAQEBAQEBAQFrKIV7EwFLDwQhASlVigesAIslgzSNawEBCGSFCiAFkXSBFI82qFiXbDYigXSBWIJlggsMQQQbggUjiWwWgiIBAQE X-IronPort-AV: E=Sophos;i="5.44,422,1505793600"; d="scan'208";a="112217803" Received: from d24-150-181-10.home.cgocable.net (HELO fedora17.home) ([24.150.181.10]) by fipsb02.cogeco.net with ESMTP; 19 Nov 2017 16:07:48 -0500 From: kramer@cogeco.ca (Bryan M. Kramer) Date: Sun, 19 Nov 2017 16:07:43 -0500 Message-ID: <87mv3i6kps.fsf@fedora17.home> MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.0 (----) copy-file help states if second argument is a directory, it will create a properly named file in the directory. This is no longer the case in this version of emacs. In GNU Emacs 27.0.50 (build 11, x86_64-pc-linux-gnu, GTK+ Version 3.22.21) of 2017-11-14 built on fedora17.home Repository revision: 13248f7444630508cfc3b78a07e8d96613af11c8 Windowing system distributor 'The Cygwin/X Project', version 11.0.11905000 Recent messages: Type "q" in help window to restore its previous buffer, C-M-v to scroll help. Mark saved where search started Mark set Mark saved where search started MATCH DM /home/bryan/afs/httpdocs /home/bryan/parallel/dm /home/bryan/parallel/dm/private/bin summarize-db-url.php M1 nil M2 /private/bin COPYING /home/bryan/parallel/dm/private/bin/summarize-db-url.php to /home/bryan/afs/httpdocs/private/bin call-diff-copy-item: Opening output file: Is a directory, /home/bryan/afs/httpdocs/private/bin Configured using: 'configure --prefix=/home/bryan/install --without-makeinfo --without-pop' Configured features: XPM JPEG TIFF GIF PNG SOUND DBUS GSETTINGS NOTIFY LIBSELINUX GNUTLS FREETYPE XFT ZLIB TOOLKIT_SCROLL_BARS GTK3 X11 Important settings: value of $LANG: en_US.UTF-8 locale-coding-system: utf-8-unix Major mode: Emacs-Lisp Minor modes in effect: diff-auto-refine-mode: t show-paren-mode: t delete-selection-mode: t tooltip-mode: t global-eldoc-mode: t eldoc-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message rmc puny format-spec rfc822 mml mml-sec epa derived epg gnus-util rmail rmail-loaddefs mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mail-utils cl-extra eieio-opt find-func help-fns radix-tree misearch multi-isearch thingatpt jka-compr ediff-merg ediff-wind ediff-diff ediff-mult ediff-help ediff-init ediff-util ediff pp vc-git diff-mode easy-mmode php-mode etags xref project ring cc-langs cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs speedbar sb-image ezimage dframe tutorial help-mode dired dired-loaddefs elec-pair server hideshow prettier-js dash edmacro kmacro timesheet srgrep more-hacks paren delsel mm-util mail-prsvr finder-inf package easymenu epg-config url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs eieio-loaddefs password-cache url-vars seq byte-opt gv bytecomp byte-compile cconv cl-loaddefs cl-lib time-date mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode lisp-mode prog-mode register page menu-bar rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite charscript charprop case-table epa-hook jka-cmpr-hook help simple abbrev obarray minibuffer cl-preloaded nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote dbusbind inotify dynamic-setting system-font-setting font-render-setting move-toolbar gtk x-toolkit x multi-tty make-network-process emacs) Memory information: ((conses 16 338902 27210) (symbols 48 32198 1) (miscs 40 221 571) (strings 32 106557 2098) (string-bytes 1 4246375) (vectors 16 29554) (vector-slots 8 718124 18908) (floats 8 85 101) (intervals 56 14889 37) (buffers 992 27)) From unknown Mon Aug 18 09:03:03 2025 X-Loop: help-debbugs@gnu.org Subject: bug#29362: 27.0.50; copy-file no longer copying when second argument is a directory Resent-From: Philipp Stephani Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 Nov 2017 21:41:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 29362 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: "Bryan M. Kramer" Cc: 29362@debbugs.gnu.org Received: via spool by 29362-submit@debbugs.gnu.org id=B29362.151112762111094 (code B ref 29362); Sun, 19 Nov 2017 21:41:01 +0000 Received: (at 29362) by debbugs.gnu.org; 19 Nov 2017 21:40:21 +0000 Received: from localhost ([127.0.0.1]:47999 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eGXK9-0002ss-KE for submit@debbugs.gnu.org; Sun, 19 Nov 2017 16:40:21 -0500 Received: from mail-qk0-f176.google.com ([209.85.220.176]:42880) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eGXK8-0002sg-8R for 29362@debbugs.gnu.org; Sun, 19 Nov 2017 16:40:20 -0500 Received: by mail-qk0-f176.google.com with SMTP id a194so5337979qkc.9 for <29362@debbugs.gnu.org>; Sun, 19 Nov 2017 13:40:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=q414yG+N6YL+1KZcy+ETWwYxre4Svxi8Oto+nlr+cqc=; b=n6sg0G6KVZYXJFtjLetCPTV0JU3PBrgqHhsFQmIhR+q8PHve2ZwvkcD/DJhPkKn3f4 1/64T6x1oXp8URVcfniqGOvgtbmoPsMAGXVS4zG8ugI3UQHE+oY/CdOc9zGNAsfdalnU TEAiAdVc9y7E6PTSFhgvulgGEK4/GrJFSpEPjz/RTfHDAWsj2IlaPb+DJBQ7rJxxL9c0 wv9j3NoDK78MHAMuVnBxrudurWRxRp4QUn9Idacy5xNSMh95UpDtwkOMKTux0i7warGJ V0GIpDirRTRt/lgHMyXEvbwdrnG8RYTlPsTTbgXW93XYF7Xcv3s22nfZyA6RWIGX0Sfj qSSA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=q414yG+N6YL+1KZcy+ETWwYxre4Svxi8Oto+nlr+cqc=; b=i0LU6Po1ec5F3dA0w/E+Jy2pZNep9V+0ebapj+Jopro/2tdG+kqDm14DYcCPr7jPY/ P8eqFfRjwB/bCkfYj2YRqYKLhV3tNex/4cwTWCMwxKZsMhoGz9Om2m9ncCOqHnILdlja dzWkhTTI2XxjNjkws8IbJ4FuNK0pvFg+ngzjQLMQDCEbnIt79XeIBquvbgHOSEfiYEHr m/uVOZzqjlVYvR6KWhBnElLbUyQ3nrGM3JeDYXQwP7gFMOUdTx8I8jleHD3S1X8gpjqh V7eyiheI1fwjrX/OGwuQxYmAk7FJwaxf99+33Umqq9RUhmtiupGQ6eEdqMqbr1/TBbhR 6AdQ== X-Gm-Message-State: AJaThX7CkAa+TE/6zwevb3e6Mkk8osMKMPuue0tkE6fFQhS2BlGsTOAB SwgDdAK5tr69XHYcby6vXI5MjkcOmbiK9ryTpRQ= X-Google-Smtp-Source: AGs4zMZQrirQuDcgFUZl4eIwnPZpvTQJaQWVN4Z1Q+JGNFrLlsiogcqjcDLZ3SUNcQVZo3WYSM+lMT8R6CaxoxWVvBg= X-Received: by 10.55.234.15 with SMTP id t15mr18081839qkj.198.1511127614641; Sun, 19 Nov 2017 13:40:14 -0800 (PST) MIME-Version: 1.0 References: <87mv3i6kps.fsf@fedora17.home> In-Reply-To: <87mv3i6kps.fsf@fedora17.home> From: Philipp Stephani Date: Sun, 19 Nov 2017 21:40:04 +0000 Message-ID: Content-Type: multipart/alternative; boundary="089e082cdadcae5b6b055e5cd0ad" X-Spam-Score: -0.9 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.9 (/) --089e082cdadcae5b6b055e5cd0ad Content-Type: text/plain; charset="UTF-8" Bryan M. Kramer schrieb am So., 19. Nov. 2017 um 22:09 Uhr: > > copy-file help states if second argument is a directory, it will create > a properly named file in the directory. This is no longer the case in > this version of emacs. > This is working as intended, see NEWS: ** Several functions that create or rename files now treat their destination argument specially only when it is a directory name, i.e., when it ends in '/' on GNU and other POSIX-like systems. When the destination argument D of one of these functions is an existing directory and the intent is to act on an entry in that directory, D should now be a directory name. For example, (rename-file "e" "f/") renames to 'f/e'. Although this formerly happened sometimes even when D was not a directory name, as in (rename-file "e" "f") where 'f' happened to be a directory, the old behavior often contradicted the documentation and had inherent races that led to security holes. A call like (rename-file C D) that used the old, undocumented behavior can be written as (rename-file C (file-name-as-directory D)), a formulation portable to both older and newer versions of Emacs. Affected functions include 'add-name-to-file', 'copy-directory', 'copy-file', 'format-write-file', 'gnus-copy-file', 'make-symbolic-link', 'rename-file', 'thumbs-rename-images', and 'write-file'. --089e082cdadcae5b6b055e5cd0ad Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


Bryan = M. Kramer <kramer@cogeco.ca> = schrieb am So., 19. Nov. 2017 um 22:09=C2=A0Uhr:

copy-file help states if second argument is a directory, it will create
a properly named file in the directory. This is no longer the case in
this version of emacs.

This is working as intended, see NEWS:

** Several functions that create or rename files now = treat their
destination argument specially only when it is a dire= ctory name, i.e.,
when it ends in '/' on GNU and other PO= SIX-like systems.=C2=A0 When the
destination argument D of one of= these functions is an existing
directory and the intent is to ac= t on an entry in that directory, D
should now be a directory name= .=C2=A0 For example, (rename-file "e" "f/")
r= enames to 'f/e'.=C2=A0 Although this formerly happened sometimes ev= en when
D was not a directory name, as in (rename-file "e&qu= ot; "f") where 'f'
happened to be a directory, = the old behavior often contradicted the
documentation and had inh= erent races that led to security holes.=C2=A0 A
call like (rename= -file C D) that used the old, undocumented behavior
can be writte= n as (rename-file C (file-name-as-directory D)), a
formulation po= rtable to both older and newer versions of Emacs.
Affected functi= ons include 'add-name-to-file', 'copy-directory',
'copy-file', 'format-write-file', 'gnus-copy-file'= ,
'make-symbolic-link', 'rename-file', 'thumb= s-rename-images', and
'write-file'.
=C2=A0<= /div>
--089e082cdadcae5b6b055e5cd0ad-- From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 20 12:59:36 2017 Received: (at control) by debbugs.gnu.org; 20 Nov 2017 17:59:36 +0000 Received: from localhost ([127.0.0.1]:49311 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eGqM3-00036G-QE for submit@debbugs.gnu.org; Mon, 20 Nov 2017 12:59:35 -0500 Received: from eggs.gnu.org ([208.118.235.92]:52612) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eGqM2-00035y-MS for control@debbugs.gnu.org; Mon, 20 Nov 2017 12:59:34 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eGqLx-0008Un-0K for control@debbugs.gnu.org; Mon, 20 Nov 2017 12:59:29 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:45524) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eGqLw-0008Uj-TV for control@debbugs.gnu.org; Mon, 20 Nov 2017 12:59:28 -0500 Received: from rgm by fencepost.gnu.org with local (Exim 4.82) (envelope-from ) id 1eGqLw-0005oa-Jg for control@debbugs.gnu.org; Mon, 20 Nov 2017 12:59:28 -0500 Subject: control message for bug 29362 To: X-Mailer: mail (GNU Mailutils 2.99.98) Message-Id: From: Glenn Morris Date: Mon, 20 Nov 2017 12:59:28 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) tag 29362 notabug close 29362