From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: JuanLeon Lahoz Newsgroups: gmane.emacs.bugs Subject: bug#14652: 24.3; ZIP files corrupted when saved via tramp Date: Tue, 18 Jun 2013 13:49:51 +0200 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=089e013a282c95636d04df6c4feb X-Trace: ger.gmane.org 1371570647 4828 80.91.229.3 (18 Jun 2013 15:50:47 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 18 Jun 2013 15:50:47 +0000 (UTC) To: 14652@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Jun 18 17:50:46 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 1UoyBC-0000qx-4h for geb-bug-gnu-emacs@m.gmane.org; Tue, 18 Jun 2013 17:50:46 +0200 Original-Received: from localhost ([::1]:43412 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UoyBB-0004gT-RO for geb-bug-gnu-emacs@m.gmane.org; Tue, 18 Jun 2013 11:50:45 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:38218) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UoyAY-0003Xs-Pk for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2013 11:50:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UoyAV-000389-C1 for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2013 11:50:06 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:59015) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UoyAV-000374-89 for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2013 11:50:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1UoyAU-0006Td-I3 for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2013 11:50:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: JuanLeon Lahoz Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 18 Jun 2013 15:50:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 14652 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.137157059524872 (code B ref -1); Tue, 18 Jun 2013 15:50:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 18 Jun 2013 15:49:55 +0000 Original-Received: from localhost ([127.0.0.1]:53331 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1UoyAM-0006T5-M4 for submit@debbugs.gnu.org; Tue, 18 Jun 2013 11:49:55 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:53692) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1UouQK-0003h8-4v for submit@debbugs.gnu.org; Tue, 18 Jun 2013 07:50:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UouQB-0003jx-3O for submit@debbugs.gnu.org; Tue, 18 Jun 2013 07:50:02 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:36959) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UouQB-0003jt-0e for submit@debbugs.gnu.org; Tue, 18 Jun 2013 07:49:59 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:55375) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UouQ7-0002Yj-Ll for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2013 07:49:58 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UouQ4-0003iT-GF for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2013 07:49:55 -0400 Original-Received: from mail-ob0-x22e.google.com ([2607:f8b0:4003:c01::22e]:36242) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UouQ4-0003iP-AG for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2013 07:49:52 -0400 Original-Received: by mail-ob0-f174.google.com with SMTP id wd20so4475260obb.33 for ; Tue, 18 Jun 2013 04:49:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=oX07gaKf7/YPjN/LR6Qg/NYYggA6Z5sIzJ3TNwilyL4=; b=XU/CRrLjFg+5eBQhKH6K9ePVy+8frWTFMHUohA5JkXcyyhZSjEhbPI6eV9gIedn+ne B7DsgR+KFaVxDgfI35qrDuAGQk5iEkdR5cnrHS09PSLq32LBYX3sQiMpbncop7YoRoP5 lzRYnLlHrs+yvNZGpYXyv4wDyc2lcqocDblqR4e4zl7qWQimQTGwIItR06KpBufILaBs qMW2Odk/V7/zO8xkkLa84hrUaf8GR4Dckl3X4Hn0HTR+VkhgKYXJ4X0VaiZ678CpuyiJ EhQEtow2PNhmkwhvUnqhc2yx/pasqXf/D08547/pWYDKZlHcwbbbKvC4xZ3Ze585JglP 3Bkw== X-Received: by 10.182.120.196 with SMTP id le4mr11901432obb.57.1371556191491; Tue, 18 Jun 2013 04:49:51 -0700 (PDT) Original-Received: by 10.76.115.169 with HTTP; Tue, 18 Jun 2013 04:49:51 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Mailman-Approved-At: Tue, 18 Jun 2013 11:49:53 -0400 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:75288 Archived-At: --089e013a282c95636d04df6c4feb Content-Type: text/plain; charset=ISO-8859-1 Dear Emacs maintainers, I start emacs with emacs -Q. Then I open two remote files (foo.tgz and foo.zip). I modify a file within both of them. I save them. foo.tgz gets upated correctly and foo.zip gets corrupted (same happens with jar files, btw, since they are zipped). [ For reproducing the issue, you don't need the foo.tgz file, I just mention that to point that other compressed formats work fine for me ]. The remote files are in a system available via SSH, so that is what tramp uses. The funny thing is that when I modify the zip file locally, it works fine and emacs does not remind me I need to save the zip file (emacs reminds me to do it with the tgz file), but remotely emacs reminds me to save the zip file. When I do, it gets corrupted. I was not sure if the problem lies within tramp or in the emacs code that deals with zip files, so I filed a bug report to tramp. Here is their answer: I would say it is due to arc-mode.el. I've checked the code shortly; it uses `call-process' internally, which is not prepared for remote files. Replacing all such calls by `process-file' was not reasonable, at least handling of temporary files must be improved as well. I recommend to file a bug report towards Emacs, by "M-x report-emacs-bug". (I would appreciate very much a way to get a patch for fixing this, if/when available) Configured using: `configure '--with-x-toolkit=gtk3'' Important settings: value of $LANG: en_US.UTF-8 locale-coding-system: utf-8-unix default enable-multibyte-characters: t Minor modes in effect: tooltip-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 blink-cursor-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 gnus-util mail-extr emacsbug message format-spec rfc822 mml easymenu mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils time-date tooltip ediff-hook vc-hooks lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list newcomment lisp-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote make-network-process dynamic-setting system-font-setting font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs) --089e013a282c95636d04df6c4feb Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Dear Emacs maintainers,

I start emacs wit= h emacs -Q.=A0 Then I open two remote files (foo.tgz and
foo.zip).=A0 I = modify a file within both of them.=A0 I save them.=A0 foo.tgz gets
upate= d correctly and foo.zip gets corrupted (same happens with jar files, btw, since they are zipped).

[ For reproducing the issue, you don't n= eed the foo.tgz file, I just mention that
to point that other= compressed formats work fine for me ].

The remote files = are in a system available via SSH, so that is what tramp uses.

The funny thing is that when I modify the zip file locally, = it works
fine and emacs does not remind me I need to save the zip file (= emacs
reminds me to do it with the tgz file), but remotely emacs reminds= me to
save the zip file.=A0 When I do, it gets corrupted.

I was not sure i= f the problem lies within tramp or in the emacs code that deals
with zip= files, so I filed a bug report to tramp.=A0 Here is their answer:

= =A0=A0 I would say it is due to arc-mode.el. I've checked the code shor= tly; it uses
=A0=A0 `call-process' internally, which is not prepared for remote file= s. Replacing
=A0=A0 all such calls by `process-file' was not reasona= ble, at least handling of
=A0=A0 temporary files must be improved as wel= l.

=A0=A0 I recommend to file a bug report towards Emacs, by "M-x report-= emacs-bug".

(I would appreciate very much a way to get a patch = for fixing this, if/when
available)

Configured using:
=A0`conf= igure '--with-x-toolkit=3Dgtk3''

Important settings:
=A0 value of $LANG: en_US.UTF-8
=A0 locale-co= ding-system: utf-8-unix
=A0 default enable-multibyte-characters: t
Minor modes in effect:
=A0 tooltip-mode: t
=A0 mouse-wheel-mode: t<= br>=A0 tool-bar-mode: t
=A0 menu-bar-mode: t
=A0 file-name-shadow-mode: t
=A0 global-font-loc= k-mode: t
=A0 font-lock-mode: t
=A0 blink-cursor-mode: t
=A0 auto-= composition-mode: t
=A0 auto-encryption-mode: t
=A0 auto-compression-= mode: t
=A0 line-number-mode: t
=A0 transient-mark-mode: t

Load-path shadows:
None found.

= Features:
(shadow sort gnus-util mail-extr emacsbug message format-spec = rfc822 mml
easymenu mml-sec mm-decode mm-bodies mm-encode mail-parse rfc= 2231
mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums
mm-u= til mail-prsvr mail-utils time-date tooltip ediff-hook vc-hooks
lisp-flo= at-type mwheel x-win x-dnd tool-bar dnd fontset image regexp-opt
fringe = tabulated-list newcomment lisp-mode register page menu-bar
rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax
face= menu font-core frame cham georgian utf-8-lang misc-lang vietnamese
tibet= an thai tai-viet lao korean japanese hebrew greek romanian slovak
czech = european ethiopic indian cyrillic chinese case-table epa-hook
jka-cmpr-hook help simple abbrev minibuffer loaddefs button faces
cus-fa= ce macroexp files text-properties overlay sha1 md5 base64 format
env cod= e-pages mule custom widget hashtable-print-readable backquote
make-netwo= rk-process dynamic-setting system-font-setting
font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs)

--089e013a282c95636d04df6c4feb--