From unknown Sat Jun 14 18:51:29 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#58507 <58507@debbugs.gnu.org> To: bug#58507 <58507@debbugs.gnu.org> Subject: Status: Emacs does not preserve the coding system Reply-To: bug#58507 <58507@debbugs.gnu.org> Date: Sun, 15 Jun 2025 01:51:29 +0000 retitle 58507 Emacs does not preserve the coding system reassign 58507 emacs submitter 58507 Juhana Sadeharju severity 58507 normal tag 58507 notabug moreinfo thanks From debbugs-submit-bounces@debbugs.gnu.org Fri Oct 14 05:44:54 2022 Received: (at submit) by debbugs.gnu.org; 14 Oct 2022 09:44:54 +0000 Received: from localhost ([127.0.0.1]:35790 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ojHFN-0002mX-EE for submit@debbugs.gnu.org; Fri, 14 Oct 2022 05:44:54 -0400 Received: from lists.gnu.org ([209.51.188.17]:43526) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ojDmL-0004hR-6e for submit@debbugs.gnu.org; Fri, 14 Oct 2022 02:02:41 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50962) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ojDmL-00045n-08 for bug-gnu-emacs@gnu.org; Fri, 14 Oct 2022 02:02:41 -0400 Received: from mail-pg1-x531.google.com ([2607:f8b0:4864:20::531]:35802) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ojDmJ-0001SB-Bg for bug-gnu-emacs@gnu.org; Fri, 14 Oct 2022 02:02:40 -0400 Received: by mail-pg1-x531.google.com with SMTP id u71so3488149pgd.2 for ; Thu, 13 Oct 2022 23:02:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=fNC1xEEcifaThiKLuOB857oR4c0L2xOZR03HiKZwKqM=; b=o3ORBOqNaZHMxkmppGoEDLVkRK9pjQbxl3nZO9ke3PJrOMt0eRUfR8konu0cIH5vPL gNyE9eW/6ZPoNbJOkPUv0u9XGecpVZzczkOPnc4vLKsmBgy/mDPeqPcoVgKSpoTuJrJF gatUjuXhaPpessi5kQIDX0JTmey2WmF30nD317eLtVYI3S2ZFyW2mDYENle4MHUOhhMs axx0O6J+aoxWFNx/0bZ63UetuFL6j+3pFN+HvM/z4q+BX3rvvwjfBloMu/5ruDZwsNFM wtlrnotiNhbuHh/Yq8XAqp5OgluNXCfCTH3ha+utoruZ9yGjd2bUdqV7F+zuqQIjIDZk 34CQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=fNC1xEEcifaThiKLuOB857oR4c0L2xOZR03HiKZwKqM=; b=JiJ7hcB9vKhpPXzJyWaVfbNxXAdhkvx24pZRSSys5mtUBTS7TrxhQJ64TGffIb5+W9 xRkYWYuh2tinq5LIVB7hK7PEU5tcJ2moKiKdm6UVngZOZvWOiAPOzmhz69tN2iwy3I9h 2lkce4CrQkcQFljwXMpDTaCoJ3T0n6TGb379rOVvSxyZWFu84pOXyWYHnB2bfu+/VvU3 k60nmumidKn0Sv7nS7jngAD+DcuwAmzjnjvytSMNVkIyTAeTAuGCveHViQ8zHYo6MGMn oQcLOgog/iYzpBsIBc7JBnxcKU6IweMG12NMP5bOKuvczwyBEofAcwb2h8mqcHiOhCPn qBcQ== X-Gm-Message-State: ACrzQf3lcd+ZDzWrkaC3kAuV9yjbaz5mbaYZqilRtcDHANv1v+xn+RQU /39Kka2mLTbn5BJxburCWf5TAZA/dIW5YSUE8Yo170W/ X-Google-Smtp-Source: AMsMyM4SfZeHqp3PwW9sBoe3Otmyd/AsXraHDzqGwBdB9u4aa0hy3toOZQPvdncmevnBKtfGS7u3ci70cqsr5pRjzXM= X-Received: by 2002:a05:6a00:4093:b0:563:2d96:8f44 with SMTP id bw19-20020a056a00409300b005632d968f44mr3768983pfb.4.1665727357284; Thu, 13 Oct 2022 23:02:37 -0700 (PDT) MIME-Version: 1.0 From: Juhana Sadeharju Date: Fri, 14 Oct 2022 09:02:25 +0300 Message-ID: Subject: Emacs does not preserve the coding system To: bug-gnu-emacs@gnu.org Content-Type: multipart/alternative; boundary="0000000000006c75e605eaf85f80" Received-SPF: pass client-ip=2607:f8b0:4864:20::531; envelope-from=johanrainhill@gmail.com; helo=mail-pg1-x531.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Fri, 14 Oct 2022 05:44:52 -0400 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: -2.3 (--) --0000000000006c75e605eaf85f80 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello. I did set the coding system to utf-8 but at quit/restart the file goes to iso-latin-dos and chars such as =C3=A4 and =C3=B6 becomes unreadabl= e. Windows 11. Both the latest Emacs and older version 25.3 has this same problem. (Windows' Note works ok and it has utf-8 set as default, unlike Emacs) --0000000000006c75e605eaf85f80 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hello. I did set the coding system to utf-8 but at quit/r= estart the file goes to iso-latin-dos and chars such as =C3=A4 and =C3=B6 b= ecomes unreadable. Windows 11. Both the latest Emacs and older version 25.3= has this same problem.

(Windo= ws' Note works ok and it has utf-8 set as default, unlike Emacs)
<= div dir=3D"auto">
--0000000000006c75e605eaf85f80-- From debbugs-submit-bounces@debbugs.gnu.org Fri Oct 14 06:42:41 2022 Received: (at 58507) by debbugs.gnu.org; 14 Oct 2022 10:42:41 +0000 Received: from localhost ([127.0.0.1]:35861 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ojI9J-0004bx-8s for submit@debbugs.gnu.org; Fri, 14 Oct 2022 06:42:41 -0400 Received: from eggs.gnu.org ([209.51.188.92]:58604) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ojI9H-0004bi-3F for 58507@debbugs.gnu.org; Fri, 14 Oct 2022 06:42:39 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:53320) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ojI9B-0001lf-Sx; Fri, 14 Oct 2022 06:42:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=gIZU8Y6C6vc5AzMfAE7SDMgFkOdEZbE8yOgAfM+kAPk=; b=gfGUypG8Po/ec7dbKOsV +NOLjJkKPNlYuxI69Tu2e0s/wBy5OTAKaPItlMReV39dwP8QRtIyIF+tBMT2Y6x6d03L4Dnef7X79 W1bSsxz0+N7fdM8NycAV2V8eNrby+vY0VyZzIkKrR/znHmfwqKHesxZD+nAm83Fprcdf5qGwywJZV xT5UZHwatVTXl08XWsid0XJl6LGN5tSveuv3nM/jb1aM6Seik1IUcCi67RN0frKwUvV3OlFhbKf6A 1UM8cBUkj//y0o0ZQ2lKn4JKbBL5vuHF532t/2W0D8Cm1YlAsj4iQsA5BxRcTH7UQZQcYSam1VyMB l0GJU+UwMhf/FQ==; Received: from [87.69.77.57] (port=4217 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ojI9B-0000gt-5e; Fri, 14 Oct 2022 06:42:33 -0400 Date: Fri, 14 Oct 2022 13:42:20 +0300 Message-Id: <83o7ue8z5f.fsf@gnu.org> From: Eli Zaretskii To: Juhana Sadeharju In-Reply-To: (message from Juhana Sadeharju on Fri, 14 Oct 2022 09:02:25 +0300) Subject: Re: bug#58507: Emacs does not preserve the coding system References: MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 58507 Cc: 58507@debbugs.gnu.org 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: -3.3 (---) > From: Juhana Sadeharju > Date: Fri, 14 Oct 2022 09:02:25 +0300 > > Hello. I did set the coding system to utf-8 but at quit/restart the file goes to iso-latin-dos and chars such as ä > and ö becomes unreadable. Windows 11. Both the latest Emacs and older version 25.3 has this same > problem. Please tell the details: how did you set coding system to utf-8, and how did you see that the file goes to iso-latin-dos. We need these details to investigate the problem. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Fri Oct 14 07:21:39 2022 Received: (at control) by debbugs.gnu.org; 14 Oct 2022 11:21:39 +0000 Received: from localhost ([127.0.0.1]:35941 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ojIl0-0005lF-SG for submit@debbugs.gnu.org; Fri, 14 Oct 2022 07:21:39 -0400 Received: from quimby.gnus.org ([95.216.78.240]:45282) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ojIky-0005l1-PS for control@debbugs.gnu.org; Fri, 14 Oct 2022 07:21:37 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=tdqtUmZ2TplMGE05yh0Uu6UhgEchf54Ga17e9K4ptfk=; b=s8izCHe/HstuYCilOjJdNzDs4H DrQUwEuWkZwDFK8+qDQB9TKRWuZIx6IFxo9iGwDQnroGFKpQOMml6zLpKETC/L3i+GFbkCrv+hNlp 0rPscxPBOwXY8WLIdrDJSoAsv3Z3/3qXHkhkEB0VcggNnR+rQHJuaB1MQ3rIttmHicWg=; Received: from [84.212.220.105] (helo=downe) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ojIkq-0005O8-9X for control@debbugs.gnu.org; Fri, 14 Oct 2022 13:21:30 +0200 Date: Fri, 14 Oct 2022 13:21:27 +0200 Message-Id: <8735bqbqh4.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #58507 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: tags 58507 + moreinfo quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) 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: -3.3 (---) tags 58507 + moreinfo quit From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 23 22:15:17 2022 Received: (at 58507) by debbugs.gnu.org; 24 Oct 2022 02:15:17 +0000 Received: from localhost ([127.0.0.1]:46718 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ommzh-0005iJ-DH for submit@debbugs.gnu.org; Sun, 23 Oct 2022 22:15:17 -0400 Received: from mail-pj1-f42.google.com ([209.85.216.42]:51160) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1omlF7-0002zv-4k for 58507@debbugs.gnu.org; Sun, 23 Oct 2022 20:23:05 -0400 Received: by mail-pj1-f42.google.com with SMTP id l6so3357879pjj.0 for <58507@debbugs.gnu.org>; Sun, 23 Oct 2022 17:23:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=pcfij7d23Wx8oxvcXpd5vizBePe9p3VUODpmf5snqyY=; b=hVmNtHjL66oIVlSKd713LdRVOd9V868LxocoMdtkLS7WGF+r4eQe+gHiHPtp5/UXz3 zIt4yudSlTgDECdMq7cghK76pfhpd/G4yGD0vz+ow8cyabSYXlnD8HRFCYficJxbevHt 1wvm4agTfI+z834RJuVqDBR1w5xgA9Y3UrDK/CG5tI/uisA5n+SGBwQpz3+eSjzcF3k4 RKRobpBh3oiudd9dVHMAEfbY4EQTNrb1ymMqc4Y4IUuGrr2Mesi/gU9vW7fLGArIYwjA A6FiAr4PvtfxpyCC1qGIE8wzcSkzRoL6+2MGor0Cwf/6clbJUeZBiALjnOJlRqTH42sm 05tA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=pcfij7d23Wx8oxvcXpd5vizBePe9p3VUODpmf5snqyY=; b=leMv9f3olHRIdl3v9bwzkj6mfR0WDOBseg0pXR1UWUOoM3dkK69SOJ91Tm1K54FFtE 0vln2IDFMPKC1dchCv9Go9GyNr2K3eFNvDYaB3CTDY+53eDmG5MC6NdBBMP5yTadVfNK cXbS56C7TK1lU2nSdCZzJbdP4OdyPoh/ACU62Mqs2YsOjvRl1DIBQv1XTmAJjGhtHnoC uIbI4DkWvLbixZJVtnc/37Sbr7ecbeOtuqeECEZA6KRYy1nWorkEfkk8qWkLMZWEA3LY zamnHwlNkYKWmc7cJJl3kseNFohlYb5AMhO9UL8EvEJuBQD00eXFpPHVmysFMx3oDFMA MU0A== X-Gm-Message-State: ACrzQf3DlD93L9HCkfmgeLagXh/JLkVjSod9gGITzT0FiTXKinNk+pU7 zrZ2BIy0t/XKfLV2RYgi5XVlZ8EIUf9I4s7w0GI= X-Google-Smtp-Source: AMsMyM61adHHgGvy8yb3XsL9Nyvv/3wIB1woHWNAR+wxquHy1wrulTVj3MYrJCtNjpU9/g78RyWN7ms7/vrpVhRA/iQ= X-Received: by 2002:a17:903:1c9:b0:186:91fa:59ad with SMTP id e9-20020a17090301c900b0018691fa59admr8184034plh.35.1666570975019; Sun, 23 Oct 2022 17:22:55 -0700 (PDT) MIME-Version: 1.0 References: <83o7ue8z5f.fsf@gnu.org> In-Reply-To: <83o7ue8z5f.fsf@gnu.org> From: Juhana Sadeharju Date: Mon, 24 Oct 2022 03:22:44 +0300 Message-ID: Subject: Re: bug#58507: Emacs does not preserve the coding system To: Eli Zaretskii Content-Type: multipart/alternative; boundary="000000000000f58a8a05ebbcca4b" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 58507 X-Mailman-Approved-At: Sun, 23 Oct 2022 22:15:10 -0400 Cc: 58507@debbugs.gnu.org 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: -1.0 (-) --000000000000f58a8a05ebbcca4b Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello. I have now tested this with versions 24.3, 25.3 and latest 28.2. All have this problem. First I create a new file with c-x c-f. By default, it has coding system iso-latin-9-dos. I change the coding system to utf-8 via the buffer's bottombar. Char "0" changes to "U". Then I write "=C3=A4=C3=B6=C3=A4=C3=B6=C3=A4=C3=B6" and quit emacs. When I rerun the emacs and open the text, the "=C3=B6=C3=A4" looks wrong an= d coding system is back at iso-latin-9-dos. I use Total Commander's View to verify the file is ok. The file goes wrong only if I now save the buffer. What helps is c-x ret r which asks the coding system -- I type utf-8. Also helps when I add ";;; -*- coding: utf-8-dos; -*-" to the top of file. I will use this method as solution, but this is too advanced for regular users -- please check what is the problem. Windows 11 Home, ver 22H2, installed 11.10.2022, HP Pavilion Gaming Desktop TG01-2xxx pe 14. lokak. 2022 klo 13.42 Eli Zaretskii kirjoitti: > > From: Juhana Sadeharju > > Date: Fri, 14 Oct 2022 09:02:25 +0300 > > > > Hello. I did set the coding system to utf-8 but at quit/restart the fil= e > goes to iso-latin-dos and chars such as =C3=A4 > > and =C3=B6 becomes unreadable. Windows 11. Both the latest Emacs and ol= der > version 25.3 has this same > > problem. > > Please tell the details: how did you set coding system to utf-8, and > how did you see that the file goes to iso-latin-dos. We need these > details to investigate the problem. > > Thanks. > --000000000000f58a8a05ebbcca4b Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hello. I have now tested this with versions 24.3, 25.3 an= d latest 28.2. All have this problem.

First I create a new file with c-x c-f. By default, it has coding= system iso-latin-9-dos.

I change the coding system to utf-8 via the buffer's bottombar. Char &= quot;0" changes to "U".

Then I write "=C3=A4=C3=B6=C3=A4=C3=B6=C3=A4=C3=B6"= ; and quit emacs.

When I= rerun the emacs and open the text, the "=C3=B6=C3=A4" looks wron= g and coding system is back at iso-latin-9-dos.

=
I use Total Commander's View to verify the file= is ok. The file goes wrong only if I now save the buffer.

What helps is c-x ret r which asks the c= oding system -- I type utf-8.

Also helps when I add ";;; -*- coding: utf-8-dos; -*-" to t= he top of file. I will use this method as solution, but this is too advance= d for regular users -- please check what is the problem.


Windows 11 Hom= e, ver 22H2, installed 11.10.2022, HP Pavilion Gaming Desktop TG01-2xxx


pe 14. lokak. 2022 klo 13.42 Eli Zaretskii &l= t;eliz@gnu.org> kirjoitti:
=
> From: Juhana Sadeharju <johanra= inhill@gmail.com>
> Date: Fri, 14 Oct 2022 09:02:25 +0300
>
> Hello. I did set the coding system to utf-8 but at quit/restart the fi= le goes to iso-latin-dos and chars such as =C3=A4
> and =C3=B6 becomes unreadable. Windows 11. Both the latest Emacs and o= lder version 25.3 has this same
> problem.

Please tell the details: how did you set coding system to utf-8, and
how did you see that the file goes to iso-latin-dos.=C2=A0 We need these details to investigate the problem.

Thanks.
--000000000000f58a8a05ebbcca4b-- From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 24 08:45:40 2022 Received: (at 58507) by debbugs.gnu.org; 24 Oct 2022 12:45:40 +0000 Received: from localhost ([127.0.0.1]:47346 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1omwpo-0005WT-IG for submit@debbugs.gnu.org; Mon, 24 Oct 2022 08:45:40 -0400 Received: from eggs.gnu.org ([209.51.188.92]:58916) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1omwpk-0005WD-TR for 58507@debbugs.gnu.org; Mon, 24 Oct 2022 08:45:39 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1omwpX-0003le-2q; Mon, 24 Oct 2022 08:45:31 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=t1qJn58wYX+2SaklRDFvGzvpsKZJ8uRYk+Db0C/Rbaw=; b=BQ357X73+tjeQV4RywvQ nFQMzuHq15v8+BDnm0H5s+DvGoN4E/FLkuWkZdYqDuOLE+392ucMrSDE6nyd03AA9LtXu/qwHqv7P t9UUh9dVFHfAHoxKXqQe5CMkUzuuMxo2K4j2QJl1DN0f+WC0ANPinKfaKDQvIJE1RJdEN5TP57nA1 W0u5jYt6BFcXyU8n8xYz4bnQfMuW2uTAwWD3DuqRC5YPJtzUR0awVyr7XvosrGcf2lEesecjjdfzQ A2BDRzt21qFrqAJoXUj/VbWC7MKXGxyGP2OfLmTOfzXMk1qAF6jX3pA2EOrzUx3GianwjH8Jlzwtz DuUyID/9jgVpOQ==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1omwpU-0007Sl-Tt; Mon, 24 Oct 2022 08:45:22 -0400 Date: Mon, 24 Oct 2022 15:45:07 +0300 Message-Id: <83a65lqtkc.fsf@gnu.org> From: Eli Zaretskii To: Juhana Sadeharju In-Reply-To: (message from Juhana Sadeharju on Mon, 24 Oct 2022 03:22:44 +0300) Subject: Re: bug#58507: Emacs does not preserve the coding system References: <83o7ue8z5f.fsf@gnu.org> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 58507 Cc: 58507@debbugs.gnu.org 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: -3.3 (---) > From: Juhana Sadeharju > Date: Mon, 24 Oct 2022 03:22:44 +0300 > Cc: 58507@debbugs.gnu.org > > First I create a new file with c-x c-f. By default, it has coding system iso-latin-9-dos. > > I change the coding system to utf-8 via the buffer's bottombar. Char "0" changes to "U". > > Then I write "äöäöäö" and quit emacs. > > When I rerun the emacs and open the text, the "öä" looks wrong and coding system is back at iso-latin-9-dos. > > I use Total Commander's View to verify the file is ok. The file goes wrong only if I now save the buffer. This is expected: the short file that you created can be interpreted both as UTF-8 and as ISO-8859-9. When there is ambiguity in detection of the encoding, Emacs prefers the locale-dependent defaults, which in your case are ISO-8859-9. > What helps is c-x ret r which asks the coding system -- I type utf-8. > > Also helps when I add ";;; -*- coding: utf-8-dos; -*-" to the top of file. I will use this method as solution, but this > is too advanced for regular users -- please check what is the problem. These are indeed two ways of telling Emacs to visit the file as encoded in UTF-8. From debbugs-submit-bounces@debbugs.gnu.org Thu Feb 09 03:56:44 2023 Received: (at 58507) by debbugs.gnu.org; 9 Feb 2023 08:56:44 +0000 Received: from localhost ([127.0.0.1]:57439 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pQ2jU-0000Wi-8F for submit@debbugs.gnu.org; Thu, 09 Feb 2023 03:56:44 -0500 Received: from mail-pg1-f172.google.com ([209.85.215.172]:40879) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pQ2jQ-0000WQ-64 for 58507@debbugs.gnu.org; Thu, 09 Feb 2023 03:56:42 -0500 Received: by mail-pg1-f172.google.com with SMTP id 24so1123950pgt.7 for <58507@debbugs.gnu.org>; Thu, 09 Feb 2023 00:56:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=UUFRbTY5xGsa6ztR4NzWWt5aor2l3EjSGxafS7m6pdw=; b=o3HJEdATj4jn+cjAKDF2q//LfNG0PH6XeLtlKSXNbXh/myRoTGJNu8I9ES4sDGvYX/ ViyKvesp5e9u0yUTLI9Cjevgxe60EMwiEUIzlW23AGnMEug3robC0NhE4a2Vsq/47tXV 3cpalPBfUaoz959us7bUt27CTHgQIYWhRtGQ4WpkODmdG+OUubAIRgkfZMy8bX4BEYF3 CwegqhBAUogP+Wke2P7MSbAMyGnxeUhUlMbQkLk6aJgGN0rRQV+vrZNMrrsxT8IwM/Fv 5eK7m/KQxY3SrYxKJ1Co7cfEb5bkJfabIXLilGL/VkpiADRgEX7Nci5saNzK9LF/CKWy jKRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=UUFRbTY5xGsa6ztR4NzWWt5aor2l3EjSGxafS7m6pdw=; b=gM+OWMovERPsIM/3+reffeiFdnRhTYqtFRuQ6PgqAW6CxjIiDTaK/EPuCTQaXmKMLm JnqamcFWx7KGF3PfNuS6mSo377ubfmJcB79NXLpa70fWY2i+i5CKtUOZu3l+C89OIKey 2b7IGfjDgFNZnjulNateZ6fXd2NBbPTaBhsbxmv2Lbfdu9XihIoHUymD6RYmDSMbkHWh jgYekbmTc5oiylfg6iHV47PYjv7WpjoWZrtHbpVtoPdWN+VkuP0lNLtdTYJZEdEfFRcU DwuijM6wH/+w+SIBbdfykWwpaykH72W3qM+ZmuvkfC6Nm/FlJqKjm78Adf1k8QVLvGRA xlcA== X-Gm-Message-State: AO0yUKXK8L1P6VDFQ0iYXQnZCZ/K/bMss/oP/FXryALzNVuGPITJfck7 iRK3k/9xGpxrOiHFR6FiXDPHWBcMIpRDOo+NVeiMdraZ X-Google-Smtp-Source: AK7set+3se5nkvjSyqY+l1XpSR4W56X0eP4BQEJJov9M2o8htZqIHOd+dH3HcsuPoDuWdXvFExhf1FdQHqjWGNKjfAA= X-Received: by 2002:a62:52c5:0:b0:5a7:c883:3d7a with SMTP id g188-20020a6252c5000000b005a7c8833d7amr1924724pfb.3.1675932993950; Thu, 09 Feb 2023 00:56:33 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Juhana Sadeharju Date: Thu, 9 Feb 2023 10:56:22 +0200 Message-ID: Subject: Re: bug#58507: Acknowledgement (Emacs does not preserve the coding system) To: 58507@debbugs.gnu.org Content-Type: multipart/alternative; boundary="000000000000c5976e05f4408eeb" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 58507 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: -1.0 (-) --000000000000c5976e05f4408eeb Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello. Has this bug or feature been fixed? The problem is that Emacs doesn't keep the coding system I have set (utf-8). The file is opened with different coding system and all =C3=A4=C3=B6 chars are a mess. Even I set t= he coding system again to utf-8, all the mess remains. Fixing the mess does not help because the next time the coding system is wrong again. Why Emacs doesn't let user to decide what is the coding system for the file= ? I'm actually scared to use Emacs anymore because Emacs has converted thousands lines of text to a mess because of this bug. There was a trick to fix the coding system by inserting commands to the start of file, so I suggest to add a command like "fix the coding system to file" which adds the trick thing to the file. I keep forgetting the trick. pe 14. lokak. 2022 klo 12.45 GNU bug Tracking System kirjoitti: > Thank you for filing a new bug report with debbugs.gnu.org. > > This is an automatically generated reply to let you know your message > has been received. > > Your message is being forwarded to the package maintainers and other > interested parties for their attention; they will reply in due course. > > Your message has been sent to the package maintainer(s): > bug-gnu-emacs@gnu.org > > If you wish to submit further information on this problem, please > send it to 58507@debbugs.gnu.org. > > Please do not send mail to help-debbugs@gnu.org unless you wish > to report a problem with the Bug-tracking system. > > -- > 58507: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D58507 > GNU Bug Tracking System > Contact help-debbugs@gnu.org with problems > --000000000000c5976e05f4408eeb Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

Hello. Has = this bug or feature been fixed? The problem is that Emacs doesn't keep = the coding system I have set (utf-8). The file is opened with different cod= ing system and all =C3=A4=C3=B6 chars are a mess. Even I set the coding sys= tem again to utf-8, all the mess remains. Fixing the mess does not help bec= ause the next time the coding system is wrong again.

Why Emacs doesn't let user to decide what = is the coding system for the file?

I'm actually scared to use Emacs anymore because Emacs has c= onverted thousands lines of text to a mess because of this bug.

There was a trick to fix the coding= system by inserting commands to the start of file, so I suggest to add a c= ommand like "fix the coding system to file" which adds the trick = thing to the file. I keep forgetting the trick.

pe 14. lokak. 2022 k= lo 12.45 GNU bug Tracking System <help-debbugs@gnu.org> kirjoitti:
Thank you for filing a new bug report with debbugs.gnu.org.

This is an automatically generated reply to let you know your message
has been received.

Your message is being forwarded to the package maintainers and other
interested parties for their attention; they will reply in due course.

Your message has been sent to the package maintainer(s):
=C2=A0
bug-gnu-emacs@gnu.org

If you wish to submit further information on this problem, please
send it to 58507@debbugs.gnu.org.

Please do not send mail to help-debbugs@gnu.org unless you wish
to report a problem with the Bug-tracking system.

--
58507: https://debbugs.gnu.org/cgi/b= ugreport.cgi?bug=3D58507
GNU Bug Tracking System
Contact help-debbugs@gnu.org with problems
--000000000000c5976e05f4408eeb-- From debbugs-submit-bounces@debbugs.gnu.org Thu Feb 09 04:52:24 2023 Received: (at 58507) by debbugs.gnu.org; 9 Feb 2023 09:52:24 +0000 Received: from localhost ([127.0.0.1]:57562 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pQ3bL-000210-QJ for submit@debbugs.gnu.org; Thu, 09 Feb 2023 04:52:24 -0500 Received: from eggs.gnu.org ([209.51.188.92]:41648) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pQ3bI-00020j-DP for 58507@debbugs.gnu.org; Thu, 09 Feb 2023 04:52:22 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pQ3bD-0001qj-2P; Thu, 09 Feb 2023 04:52:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=3zZyKuwrD460NUFp1CDRkdp55usrcjfox+lRx3PKtL0=; b=FG2QSwq7gXIxEG72iI0j nC5S+qAkSVoHFG5AVuKmF56PofNrSOtm8jBHlWv6Qs3nVpWClcStmhUhR8fbwq2MOUP/sNNfmuUBR 4KpE/g+pgKwO0smZPZ2oIeYurZ5X32dGvK2CFJIMhGouXUttX44d2M4N+OCIbW0Sr+8EwdDcSdUZ+ 5O1ndm725fvpj26tn2xsEYIJW1Z3GqgVedqQ38OGpoUEDL8tsNYrZ3JHJxnK97nXrSKIDHjBwvvBK A8TJBL6DUx0RrF4aVgLPIBGOJO+EcDgzWJfGEnn2zfcsF2I3po/ECp+Sv5chhRE2k3XUeY5/1eWkE f4VrhP/Z6LG5mw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pQ3b0-0004Ft-LN; Thu, 09 Feb 2023 04:52:14 -0500 Date: Thu, 09 Feb 2023 11:52:22 +0200 Message-Id: <83edqzmai1.fsf@gnu.org> From: Eli Zaretskii To: Juhana Sadeharju In-Reply-To: (message from Juhana Sadeharju on Thu, 9 Feb 2023 10:56:22 +0200) Subject: Re: bug#58507: Acknowledgement (Emacs does not preserve the coding system) References: MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 58507 Cc: 58507@debbugs.gnu.org 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: -3.3 (---) > From: Juhana Sadeharju > Date: Thu, 9 Feb 2023 10:56:22 +0200 > > Hello. Has this bug or feature been fixed? We made no change to Emacs due to this report, since I don't believe there's a bug here. This is how Emacs behaves, and this behavior is well documented and intended. In previous discussion of this issue, I pointed out how to deal with such situations; I repeat some of that below. > The problem is that Emacs doesn't keep the coding system I have > set (utf-8). The information about the file's encoding, if you want to keep it, should be in the file, using the 'coding:' cookie, by adding ";;; -*- coding: utf-8-dos; -*-" in the first line of the file. (You can also do this in the file's Local Variables section near the end of the file; see the "Specifying File Variables" node of the Emacs user manual for details. Alternatively, you can force Emacs to use UTF-8 when you visit the file: C-x RET c utf-8 RET C-x C-f RET The "C-x RET c utf-8 RET" prefix forces the following command to use UTF-8 for decoding and encoding text. > The file is opened with different coding system and all äö chars are a mess. Even I set the coding > system again to utf-8, all the mess remains. Fixing the mess does not help because the next time the coding > system is wrong again. > > Why Emacs doesn't let user to decide what is the coding system for the file? It does, see above. > I'm actually scared to use Emacs anymore because Emacs has converted thousands lines of text to a > mess because of this bug. As long as you only visit the file and don't make any changes to it, the "mess" on the screen is just a display problem; the file's contents is not changed. > There was a trick to fix the coding system by inserting commands to the start of file, so I suggest to add a > command like "fix the coding system to file" which adds the trick thing to the file. I keep forgetting the trick. The command is "C-x RET r". This re-reads the file after prompting you for the coding-system to decode the file's contents. Which is yet another alternative to "fix" the problem after you visit the file and notice the incorrect guess of its coding-system. From debbugs-submit-bounces@debbugs.gnu.org Sun Sep 03 05:30:38 2023 Received: (at 58507) by debbugs.gnu.org; 3 Sep 2023 09:30:38 +0000 Received: from localhost ([127.0.0.1]:39473 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qcjRG-0000WS-5m for submit@debbugs.gnu.org; Sun, 03 Sep 2023 05:30:38 -0400 Received: from mail-lf1-x135.google.com ([2a00:1450:4864:20::135]:60746) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qcjRD-0000CH-CL for 58507@debbugs.gnu.org; Sun, 03 Sep 2023 05:30:36 -0400 Received: by mail-lf1-x135.google.com with SMTP id 2adb3069b0e04-50087d47d4dso903772e87.1 for <58507@debbugs.gnu.org>; Sun, 03 Sep 2023 02:30:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1693733419; x=1694338219; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:from:to:cc:subject:date:message-id:reply-to; bh=vMZnRk1IAkbQfjK1o8FaBTQhCmlSM4EQudEzl+WEiBs=; b=gOSRAxnKjf+q5y7AUtnVxkLWcOVp3VLkGiok2DLW2IqQTXP5tBmsYNST2W3eSR/cSG jyC4wC+byIFLXCBB02l2IR0EFco+5ziE5r8cnknc4CQphiyNOUER2pO9y+ncN4etPWuI shu6o9CIpvkI3I6x+VvZB6+cDQ6Ie+X04qB8Ktd/oxGEFI4HKCM02z3Wndk/B/oEiv2w QtA7yTvJoVFXYTMuZtrRQw8KUru0jpRAXnVrvi4CbB7q9TN6S8NHE86vP5WCQX5YE+5h ojrfS6RqlvcRM14kLGlqeRsHCxfEvtt+NVIY1DPUayof90m9tAtrAoAjij74Q7nYLCgX NCWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693733419; x=1694338219; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=vMZnRk1IAkbQfjK1o8FaBTQhCmlSM4EQudEzl+WEiBs=; b=h622/rSDYBXReqFoRxZNHmZgHgn/lHwI6evhzOYHLAbdmQcBjiv5OvVxxunmyOefGD ZNLoCqEUi0oGCoqWdFJnRzCnAImD72oebUnEPRb+kwrcL3nT4PEG++05oW+vFZ+HOisX 056TTM909wl1qKFnCrbjcIZUdTqSPZCBTDuMlYjzu7xHqV91b4i+uyzk7ya448XX3YbH /EC1tbB7rpFwbinN17t6FlAE4lpwONKgI1Hq12OH/q03ZfZ3I1HjS/C4/Ius7mqQPrNL VyUnkFbw/kGfZx/V2DrKyFBOtpJy8jqfa4lHcOMjPxc8HzUPZNY0OWG2Yk4SJQ7aPekA TD/A== X-Gm-Message-State: AOJu0YwKQwhOANTVXDdJDWNRV8KxQ0scXSsK91gfG2xsEIJdkt3jFs1j joCFZWintUXkiZD46lcvlYwz7UOvuSa26zA+DX0= X-Google-Smtp-Source: AGHT+IHoQagJlBEAOMuI4zlZPsbqAEqd873wNFijTVEdRLCvp1XOEa2Q0gaqVlAMw8IFwvuaDxwJjYMGdBeNItC48sM= X-Received: by 2002:a05:6512:39c6:b0:500:9de4:5968 with SMTP id k6-20020a05651239c600b005009de45968mr6239859lfu.59.1693733419024; Sun, 03 Sep 2023 02:30:19 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Sun, 3 Sep 2023 02:30:18 -0700 From: Stefan Kangas In-Reply-To: <83edqzmai1.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 09 Feb 2023 11:52:22 +0200") References: <83edqzmai1.fsf@gnu.org> MIME-Version: 1.0 Date: Sun, 3 Sep 2023 02:30:18 -0700 Message-ID: Subject: Re: bug#58507: Emacs does not preserve the coding system To: Eli Zaretskii Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 58507 Cc: 58507@debbugs.gnu.org, Juhana Sadeharju 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: -1.0 (-) tags 58507 notabug close 58507 thanks Eli Zaretskii writes: >> From: Juhana Sadeharju >> Date: Thu, 9 Feb 2023 10:56:22 +0200 >> >> Hello. Has this bug or feature been fixed? > > We made no change to Emacs due to this report, since I don't believe > there's a bug here. This is how Emacs behaves, and this behavior is > well documented and intended. Thanks. I'm therefore closing this bug report. From unknown Sat Jun 14 18:51:29 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 01 Oct 2023 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator