all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Bug with UTF-8 string and dbus
@ 2010-06-08 21:39 Julien Danjou
  2010-06-09  0:43 ` Stefan Monnier
  2010-06-09  9:16 ` [PATCH] Fix D-Bus string encoding Julien Danjou
  0 siblings, 2 replies; 23+ messages in thread
From: Julien Danjou @ 2010-06-08 21:39 UTC (permalink / raw)
  To: emacs-devel

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

Hi,

While coding notifications.el, I found an odd bug here.
When using it with some UTF-8 chars in a string (like 'title' or
'body'), Emacs raises a D-Bus error because it did not received a reply.
But reading dbus-monitor, it did NOT send a method call.

I can reproduce it easily with:

  (dbus-call-method :session
                    "org.freedesktop.Notifications"
                    "/org/freedesktop/Notifications"
                    "org.freedesktop.Notifications"
                    "Notify"
                    :string "Emacsé")

(this is not a valid call for Notify, but anyhow it should send the
call)

I've tried to break on inside dbus.c:xd_append_arg and what I got is:
492		  char *val = SDATA (Fstring_make_unibyte (object));
(gdb) print (char *) val
$6 = 0x253e830 "Emacs", <incomplete sequence \351>

Is this normal? If yes, how to fix? If no, where's the bug?

Thanks,
-- 
Julien Danjou
// ᐰ <julien@danjou.info>   http://julien.danjou.info

[-- Attachment #2: Type: application/pgp-signature, Size: 197 bytes --]

^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2010-06-10  8:05 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-08 21:39 Bug with UTF-8 string and dbus Julien Danjou
2010-06-09  0:43 ` Stefan Monnier
2010-06-09  1:17   ` Eli Zaretskii
2010-06-09  6:34     ` Julien Danjou
2010-06-09  7:27       ` Eli Zaretskii
2010-06-09  8:51         ` Jan Djärv
2010-06-09  9:30           ` Eli Zaretskii
2010-06-09  7:28       ` Jan Djärv
2010-06-09 14:08       ` Stefan Monnier
2010-06-09 14:24         ` Julien Danjou
2010-06-09 15:01         ` Andreas Schwab
2010-06-09 15:39           ` Michael Albinus
2010-06-09 18:11           ` Stefan Monnier
2010-06-09 19:45             ` Davis Herring
2010-06-09 20:30             ` Andreas Schwab
2010-06-09 20:42               ` David Kastrup
2010-06-09 22:19         ` Andreas Schwab
     [not found]           ` <19472.35590.940217.577634@uwakimon.sk.tsukuba.ac.jp>
2010-06-10  8:05             ` Andreas Schwab
2010-06-09  9:16 ` [PATCH] Fix D-Bus string encoding Julien Danjou
2010-06-10  0:20   ` Stefan Monnier
2010-06-10  1:56     ` Eli Zaretskii
2010-06-10  2:48       ` Miles Bader
2010-06-10  3:49         ` Eli Zaretskii

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.