From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel,gmane.emacs.pretest.bugs Subject: Re: Crashes with non-default language environments Date: Mon, 11 Feb 2008 00:48:40 +0200 Organization: JURTA Message-ID: <87prv4l96f.fsf@jurta.org> References: <87y79wve9b.fsf@jurta.org> <87zlu96bp2.fsf@jurta.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1202684481 6648 80.91.229.12 (10 Feb 2008 23:01:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 10 Feb 2008 23:01:21 +0000 (UTC) Cc: emacs-pretest-bug@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Feb 11 00:01:44 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JOLB7-0002kx-Bx for ged-emacs-devel@m.gmane.org; Mon, 11 Feb 2008 00:01:41 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JOLAe-0008S5-4D for ged-emacs-devel@m.gmane.org; Sun, 10 Feb 2008 18:01:12 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JOLAZ-0008RI-97 for emacs-devel@gnu.org; Sun, 10 Feb 2008 18:01:07 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JOLAW-0008Qq-Sc for emacs-devel@gnu.org; Sun, 10 Feb 2008 18:01:06 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JOLAW-0008Qm-Q6 for emacs-devel@gnu.org; Sun, 10 Feb 2008 18:01:04 -0500 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JOLAW-00046n-GR for emacs-devel@gnu.org; Sun, 10 Feb 2008 18:01:04 -0500 Original-Received: from mx10.gnu.org ([199.232.76.166]) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1JOLAW-0007nm-7S for emacs-pretest-bug@gnu.org; Sun, 10 Feb 2008 18:01:04 -0500 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1JOLAS-00046H-RG for emacs-pretest-bug@gnu.org; Sun, 10 Feb 2008 18:01:03 -0500 Original-Received: from anti-4.kiev.sovam.com ([62.64.120.202]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JOLAS-00045p-GQ for emacs-pretest-bug@gnu.org; Sun, 10 Feb 2008 18:01:00 -0500 Original-Received: from [83.170.232.243] (helo=smtp.svitonline.com) by anti-4.kiev.sovam.com with esmtp (Exim 4.67) (envelope-from ) id 1JOLAK-000N4N-W3; Mon, 11 Feb 2008 01:00:57 +0200 In-Reply-To: (Stefan Monnier's message of "Sat, 09 Feb 2008 21:09:04 -0500") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) X-Scanner-Signature: 1e897a521fdb5eac39b1f944f187ca57 X-DrWeb-checked: yes X-SpamTest-Envelope-From: juri@jurta.org X-SpamTest-Group-ID: 00000000 X-SpamTest-Header: Not Detected X-SpamTest-Info: Profiles 2212 [Feb 10 2008] X-SpamTest-Info: helo_type=3 X-SpamTest-Info: {HEADERS: header Content-Type found without required header Content-Transfer-Encoding} X-SpamTest-Info: {TO: local part of email appears in body} X-SpamTest-Method: none X-SpamTest-Rate: 20 X-SpamTest-Status: Not detected X-SpamTest-Status-Extended: not_detected X-SpamTest-Version: SMTP-Filter Version 3.0.0 [0255], KAS30/Release X-detected-kernel: by monty-python.gnu.org: FreeBSD 6.x (1) X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:88681 gmane.emacs.pretest.bugs:20998 Archived-At: >> This crash is caused by the corrupt byte-code produced by >> `byte-compile-lapcode'. `string-make-unibyte' at the end of this >> function produces different bytecode strings in different >> language environments. This problem can be narrowed down to: > > Shouldn't it be string-to-unibyte instead? I've just checked that `string-as-unibyte' produces even worse results than `string-make-unibyte'. It replaces every byte in the original string with 2-byte sequences. The change to use `string-as-unibyte' came from the Unicode branch: 2008-02-02 Kenichi Handa * emacs-lisp/bytecomp.el (byte-compile-lapcode): Be sure to return a unibyte string. Maybe, this change is correct, but the bug is in the definition of the language environment, I can't say for sure. Comparing results of calling `string-make-unibyte' on 256 bytes in different language environments gives only 6 differences: \240 -> \232 \251 -> \277 \260 -> \234 \262 -> \235 \267 -> \236 \367 -> \237 -- Juri Linkov http://www.jurta.org/emacs/