[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#4730: 23.1; tar-chown-entry corrupts tar file

From: Dan McCarthy
Subject: bug#4730: 23.1; tar-chown-entry corrupts tar file
Date: Thu, 15 Oct 2009 12:31:21 -0400

If I'm editing a tar file, and I change a subfile's owner or group, I
get the following:

Debugger entered--Lisp error: (cl-assertion-failed (not (or enable-multibyte-cha
racters (multibyte-string-p new-data-string))))
  signal(cl-assertion-failed ((not (or enable-multibyte-characters ...))))
  tar-alter-one-field(265 "root  tar-chown-entry("root")
  call-interactively(tar-chown-entry nil nil)

and tar will be unable to read that particular tar header. I'm
able to work around it with the following advice:

(defadvice tar-alter-one-field (around fix-multibyte-input)
  (let ((new-data-string (ad-get-arg 1)))
    (if (multibyte-string-p new-data-string)
        (ad-set-arg 1 (string-to-unibyte new-data-string)))

This is on a Debian 4.0 box with GNU tar 1.16.

In GNU Emacs 23.1.1 (i686-pc-linux-gnu, GTK+ Version 2.8.20)
 of 2009-08-03 on discordia
Windowing system distributor `The X.Org Foundation', version 11.0.70101000
configured using `configure  '--with-x-toolkit=gtk''

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: en_US.UTF-8
  value of $XMODIFIERS: nil
  locale-coding-system: utf-8-unix
  default-enable-multibyte-characters: t

Major mode: Tar

Minor modes in effect:
  tooltip-mode: t
  tool-bar-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  global-auto-composition-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
<help-echo> <help-echo> <help-echo> <help-echo> <help-echo>
<help-echo> <help-echo> <help-echo> <help-echo> <help-echo>
<help-echo> <help-echo> <help-echo> <help-echo> <help-echo>
<help-echo> <down-mouse-1> <mouse-1> C-x C-f f o o
<tab> . t <tab> <return> M-x t o g g l e - d e b u
g - <tab> e <tab> <return> O <C-backspace> r o o t
<return> <help-echo> <help-echo> <help-echo> <help-echo>
<down-mouse-1> <mouse-1> M-x r e p o <tab> r t - =
<backspace> e m a c s - b u g <return>

Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Parsing tar file...done
Loading vc-svn...done
Debug on Error enabled globally
Entering debugger...
Buffer foo.tar has shrunk a lot; auto save disabled in that buffer until next re
al save
Making completion list...

reply via email to

[Prev in Thread] Current Thread [Next in Thread]