Subject: bug#7517: 24.0.50; repeated crash under Mac OS X

From: Jan Djärv <[email-masked]>
Date: Fri, 31 Dec 2010 14:10:45 +0100

Eli Zaretskii skrev 2010-12-31 13.53:
>> Date: Fri, 31 Dec 2010 12:23:54 +0100
>> From: Jan Djärv<[email-masked]>
>> Cc: [email-masked], Chong Yidong<[email-masked]>,
>> 	Stefan Monnier<[email-masked]>, [email-masked]
>>
>> On further thought, it isn't a filename, that would start with / (assuming
>> buffer filenames are always absolute).  In that case, the question is how a
>> buffer name can be a unibyte string?
>
> Some bad interaction between VM and Emacs?

That may be, but I was under the impression that Emacs internally should use 
unicode, so why is it even allowed to set such a buffer name?  Shouldn't Emacs 
internals complain when given such strings, or convert them (if charset info 
is available)?

This will break for X also, as the title setting code assumes ENCODE_UTF_8 
will do the trick, and then sets an UTF8_STRING as title.  There has been some 
VM-related bugs reported for Gtk+ also.  This may be the source of a memory 
corruption.

Is setting buffer name with a non-ascii unibyte string considered as a bug? 
Then this is a VM bug, but perhaps the title setting code should detect this also.

	Jan D.