all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: owner@emacsbugs.donarmstrong.com (Emacs bug Tracking System)
To: Chong Yidong <cyd@stupidchicken.com>
Subject: bug#2878: marked as done (bindat-pack returns unibyte string for  emacs 22 but multibyte string  for emacs 23)
Date: Mon, 04 May 2009 01:25:04 +0000	[thread overview]
Message-ID: <handler.2878.D2878.124139988011923.ackdone@emacsbugs.donarmstrong.com> (raw)
In-Reply-To: 9caafe030904030820i4dbda89coc97dc2066f8b1a05@mail.gmail.com

[-- Attachment #1: Type: text/plain, Size: 978 bytes --]


Your message dated Sun, 03 May 2009 21:18:02 -0400
with message-id <87vdohoed1.fsf@cyd.mit.edu>
and subject line Re: bug#2878: Acknowledgement (bindat-pack returns unibyte string for  emacs 22 but multibyte string for emacs 23)
has caused the Emacs bug report #2878,
regarding bindat-pack returns unibyte string for emacs 22 but multibyte string  for emacs 23
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@emacsbugs.donarmstrong.com
immediately.)


-- 
2878: http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=2878
Emacs Bug Tracking System
Contact owner@emacsbugs.donarmstrong.com with problems

[-- Attachment #2: Type: message/rfc822, Size: 3500 bytes --]

From: Yee Keat Phuah <ykphuah@gmail.com>
To: emacs-pretest-bug@gnu.org
Subject: bindat-pack returns unibyte string for emacs 22 but multibyte string  for emacs 23
Date: Fri, 3 Apr 2009 23:20:56 +0800
Message-ID: <9caafe030904030820i4dbda89coc97dc2066f8b1a05@mail.gmail.com>

Hi,

This piece of code returned nil on emacs 22 and t on emacs 23.
(let* ((spec `((:method-id     vec 4)))
       (data  `((:ref-type  . ,(vector #x00 #x00 #x00 #x00 #x00 #x00 #x00 #x39))
		(:method-id . ,(vector #x09 #x90 #xec #xd8))))
       (packed (bindat-pack spec data)))
  (multibyte-string-p packed))

And because of it being multibyte, when i want to send it over the
wire to a sub process in a binary data format, it gets transformed and
the sub process does not get a byte-by-byte equivalent of the
concatenation of the 2 vectors above. I have tried using
string-as-unibyte and the effect is still the same.

-- 
Cheers,
Phuah Yee Keat



[-- Attachment #3: Type: message/rfc822, Size: 2254 bytes --]

From: Chong Yidong <cyd@stupidchicken.com>
To: Miles Bader <miles@gnu.org>
Cc: Yee Keat Phuah <ykphuah@gmail.com>, 2878-done@emacsbugs.donarmstrong.com
Subject: Re: bug#2878: Acknowledgement (bindat-pack returns unibyte string for  emacs 22 but multibyte string for emacs 23)
Date: Sun, 03 May 2009 21:18:02 -0400
Message-ID: <87vdohoed1.fsf@cyd.mit.edu>

Miles Bader <miles@gnu.org> writes:

> I think it should be checked in.  I don't have intimate familiarity
> with this code, but I did look at the problem and make the patch.
>
> The other code in the file stores numerical values into the
> `bindat-raw' using aset, and then wants to return the whole thing as a
> unicode string containing those byte values.  The old code made a
> vector, stored into it, and turned the vector into a string using
> `concat' -- however that ends up making a _multibyte_ string (I don't
> know whether this is a bug in concat or not).  The new method of
> making a string initially and storing directly into it results in a
> unibyte string, which is what is desired (this method is also more
> efficient).

OK, I've checked in your fix.  Thanks.


      parent reply	other threads:[~2009-05-04  1:25 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <87vdohoed1.fsf@cyd.mit.edu>
2009-04-03 15:20 ` bug#2878: bindat-pack returns unibyte string for emacs 22 but multibyte string for emacs 23 Yee Keat Phuah
     [not found]   ` <handler.2878.B.123877206328398.ack@emacsbugs.donarmstrong.com>
2009-04-03 16:01     ` bug#2878: Acknowledgement (bindat-pack returns unibyte string for emacs 22 but multibyte string for emacs 23) Yee Keat Phuah
2009-05-04  1:25   ` Emacs bug Tracking System [this message]

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

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

  git send-email \
    --in-reply-to=handler.2878.D2878.124139988011923.ackdone@emacsbugs.donarmstrong.com \
    --to=owner@emacsbugs.donarmstrong.com \
    --cc=cyd@stupidchicken.com \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.