[Bug 13124] Setting your own alias unimplemented

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Mon Jul 19 23:34:13 CEST 2010


https://bugs.freedesktop.org/show_bug.cgi?id=13124

Felipe Contreras <felipe.contreras at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |felipe.contreras at gmail.com

--- Comment #11 from Felipe Contreras <felipe.contreras at gmail.com> 2010-07-19 14:34:13 PDT ---
Hmm, all bugzillas I've seen add me to the Cc list by default... I just noticed
I didn't receive a notification of this comment =/

(In reply to comment #10)
> Review of attachment 37172 [details]:
> 
> You're right that producing change notification signals is desirable, so your
> patch is better than mine; thanks!
> 
> I think your patch is likely to end up with the change notification getting out
> of sync with the state recovery, due to Bug #25869? It's better than nothing,
> though.

Well, it works fine on Maemo5 and Empathy: I see my nickname on the chat
window.

> (What I mean by that is: calling RequestAliases or whatever, just after the
> change signal, won't give the same answer as the signal)
> 
> I'd be inclined to not do the error reporting yet (i.e. behave like we both did
> here); I'll open a bug for the lack of error reporting.
> 
> ::: src/connection-aliasing.c
> @@ +179,2 @@
>  static void
> +set_alias_succeess_cb (PurpleAccount *account,
> 
> It's spelled "success" :-)

Agh, typo.

> @@ +189,3 @@
> +    g_value_init (&entry, HAZE_TP_ALIAS_PAIR_TYPE);
> +    g_value_take_boxed (&entry,
> +        dbus_g_type_specialized_construct (HAZE_TP_ALIAS_PAIR_TYPE));
> 
> It'd be better to include <telepathy-glib/gtypes.h> and use
> TP_STRUCT_TYPE_ALIAS_PAIR (we should kill off all the HAZE_TP_*_TYPE at some
> point, now that telepathy-glib generates them all).

Ok, I just copy-pasted the code from somewhere else.

> With the change I suggest below, this wouldn't be necessary anyway.
> 
> @@ +197,3 @@
> +
> +    aliases = g_ptr_array_sized_new (1);
> +    g_ptr_array_add (aliases, g_value_get_boxed (&entry));
> 
> We know that TP_STRUCT_TYPE_ALIAS_PAIR is a GValueArray<uint,string>, so since
> telepathy-glib 0.9.2 (sadly not available on Maemo 5), you could delete @entry
> entirely, and use:
> 
> aliases = g_ptr_array_sized_new (1);
> g_ptr_array_add (aliases, tp_value_array_build (2,
>     G_TYPE_UINT, base_conn->self_handle,
>     G_TYPE_STRING, new_alias,
>     G_TYPE_INVALID));
> 
> To make backporting to Maemo 5 easier, perhaps you could implement my other
> suggestions from above (producing a patch suitable for backporting to Maemo),
> then do this simplification as a second patch?

Ok, but I think the first patch should be just like the current patch... The
second one might be of wider scope touching other parts of the code that have
the same issues.

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.



More information about the telepathy-bugs mailing list