From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: [HELP] (bug?) Saving a buffer without any conversion? Date: Fri, 17 Jan 2003 04:23:07 -0500 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: References: <87fzrxszs8.fsf@lexx.delysid.org> <200301150116.KAA09223@etlken.m17n.org> <5xk7h67k1b.fsf@kfs2.cua.dk> <200301151059.TAA09873@etlken.m17n.org> <5xbs2i7dc4.fsf@kfs2.cua.dk> Reply-To: rms@gnu.org NNTP-Posting-Host: main.gmane.org X-Trace: main.gmane.org 1042795440 5914 80.91.224.249 (17 Jan 2003 09:24:00 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Fri, 17 Jan 2003 09:24:00 +0000 (UTC) Cc: handa@m17n.org Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18ZSjF-0001X6-00 for ; Fri, 17 Jan 2003 10:23:57 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 18ZSsb-0003LF-00 for ; Fri, 17 Jan 2003 10:33:37 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18ZSj4-0001uA-04 for emacs-devel@quimby.gnus.org; Fri, 17 Jan 2003 04:23:46 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10.13) id 18ZSiq-0001sA-00 for emacs-devel@gnu.org; Fri, 17 Jan 2003 04:23:32 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) id 18ZSio-0001rW-00 for emacs-devel@gnu.org; Fri, 17 Jan 2003 04:23:31 -0500 Original-Received: from fencepost.gnu.org ([199.232.76.164]) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18ZSiR-0001lB-00 for emacs-devel@gnu.org; Fri, 17 Jan 2003 04:23:07 -0500 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.10) id 18ZSiR-0007vD-00; Fri, 17 Jan 2003 04:23:07 -0500 Original-To: storm@cua.dk (Kim F. Storm) In-reply-to: <5xbs2i7dc4.fsf@kfs2.cua.dk> (storm@cua.dk) Original-cc: emacs-devel@gnu.org Original-cc: mlang@delysid.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Emacs development discussions. List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:10797 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:10797 If the process' input coding system is no-conversion or raw-text, the string argument to the filter function is a unibyte string; otherwise it is a multibyte string. Use `string-as-multibyte' on a unibyte string before inserting it in a multibyte buffer. You might or might no want to use string-as-multibyte, depending on what results you want to get. In any case, I have just confirmed that if you DON'T use a filter function, but rather relies on emacs itself to insert received data into the buffer, it works nicely even with a multibyte buffer. Does that mean it does the equivalent of using string-as-multibyte?