unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Rob Browning <rlb@defaultvalue.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 696026-forwarded@bugs.debian.org, vincent@vinc17.net,
	696026@bugs.debian.org, 13505@debbugs.gnu.org
Subject: bug#13505: Bug#696026: emacs24: file corruption on saving
Date: Sun, 20 Jan 2013 11:31:12 -0600	[thread overview]
Message-ID: <87ehhf69sv.fsf@trouble.defaultvalue.org> (raw)
In-Reply-To: <83obgjpzod.fsf@gnu.org> (Eli Zaretskii's message of "Sun, 20 Jan 2013 18:49:38 +0200")

Eli Zaretskii <eliz@gnu.org> writes:

> More to the point: there seems to be a fundamental misunderstanding
> here regarding the effect of selecting an encoding at save time.  It
> sounds like the OP thought that selecting a "literal" encoding, such
> as raw-text, which is supposed to leave the binary stream unaltered
> (apart of the EOL format), will ensure that a buffer will be saved
> exactly as it was originally found on disk.  But this is false.  What
> raw-text and no-conversion do is to write out the _internal_
> representation of each character without any conversions.  The
> original encoded form of the characters as found on disk at visit time
> _cannot_ be recovered by saving with raw-text, because that encoded
> form is lost without a trace when the file is _visited_ and decoded
> into the internal representation.  The only information that's left is
> the coding-system used to decode the characters.  But since the file's
> encoding in this case is inconsistent, that coding-system cannot be
> used to save it back (Emacs will not let you do so, as demonstrated in
> the report), and therefore the original form cannot be recovered this
> way.

Ahh, right; that make sense to me.

-- 
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2011-07-10 E6A9 DA3C C9FD 1FF8 C676 D2C4 C0F0 39E9 ED1B 597A
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4





  reply	other threads:[~2013-01-20 17:31 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20121215223809.GA7549@xvii.vinc17.org>
2013-01-20  4:09 ` bug#13505: Bug#696026: emacs24: file corruption on saving Rob Browning
2013-01-20 16:49   ` Eli Zaretskii
2013-01-20 17:31     ` Rob Browning [this message]
2013-01-20 20:24     ` Glenn Morris
2013-01-20 21:25     ` Vincent Lefevre
2013-01-20 21:40       ` Eli Zaretskii
2013-01-20 22:10         ` Vincent Lefevre
2013-01-20 22:22           ` Vincent Lefevre
2013-01-21  3:49             ` Eli Zaretskii
2013-01-21  3:48           ` Eli Zaretskii
2013-01-21  4:14             ` Vincent Lefevre
2013-01-21 17:55               ` Eli Zaretskii
2013-01-22  2:35                 ` Vincent Lefevre
2013-01-22  7:56                   ` Eli Zaretskii
2013-01-20 23:01     ` Andreas Schwab
2013-01-20 23:27       ` bug#13505: Bug#696026: " Rob Browning

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ehhf69sv.fsf@trouble.defaultvalue.org \
    --to=rlb@defaultvalue.org \
    --cc=13505@debbugs.gnu.org \
    --cc=696026-forwarded@bugs.debian.org \
    --cc=696026@bugs.debian.org \
    --cc=eliz@gnu.org \
    --cc=vincent@vinc17.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).