After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 675292 - Assertion when joining IRC channel
Assertion when joining IRC channel
Status: RESOLVED FIXED
Product: folks
Classification: Platform
Component: Telepathy backend
git master
Other Linux
: Normal normal
: Unset
Assigned To: folks-maint
folks-maint
Depends on:
Blocks:
 
 
Reported: 2012-05-02 12:22 UTC by Guillaume Desmottes
Modified: 2012-05-04 16:21 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Initialise Tpf.PersonaStore._favourite_ids correctly (2.34 KB, patch)
2012-05-03 21:50 UTC, Philip Withnall
committed Details | Review

Description Guillaume Desmottes 2012-05-02 12:22:00 UTC
I got this when joining an IRC channel with at least one participant.
Folks and Empathy master.


** (empathy-chat:14431): CRITICAL **: gee_abstract_collection_contains: assertion `self != NULL' failed

Program received signal SIGTRAP, Trace/breakpoint trap.
0x00007ffff48a5070 in g_logv (log_domain=0x0, log_level=G_LOG_LEVEL_CRITICAL, format=0x7ffff4927d40 "%s: assertion `%s' failed", args1=0x7fffffffdd88)
    at gmessages.c:758
758			G_BREAKPOINT ();
(gdb) bt
  • #0 g_logv
    at gmessages.c line 758
  • #1 g_log
    at gmessages.c line 792
  • #2 g_return_if_fail_warning
    at gmessages.c line 801
  • #3 gee_abstract_collection_contains
    at abstractcollection.c line 225
  • #4 gee_abstract_collection_contains
    at abstractcollection.c line 224
  • #5 _tpf_persona_store_ensure_persona_for_contact
    at /home/cassidy/gnome/folks/backends/telepathy/lib/tpf-persona-store.vala line 970
  • #6 tpf_persona_dup_for_contact
    at /home/cassidy/gnome/folks/backends/telepathy/lib/tpf-persona.vala line 1137
  • #7 empathy_create_individual_from_tp_contact
    at empathy-utils.c line 1195
  • #8 add_members
    at empathy-individual-store-channel.c line 84
  • #9 channel_prepare_cb
    at empathy-individual-store-channel.c line 163
  • #10 g_simple_async_result_complete
    at gsimpleasyncresult.c line 767
  • #11 complete_in_idle_cb
    at gsimpleasyncresult.c line 779
  • #12 g_idle_dispatch
    at gmain.c line 4657
  • #13 g_main_dispatch
    at gmain.c line 2539
  • #14 g_main_context_dispatch
    at gmain.c line 3075
  • #15 g_main_context_iterate
    at gmain.c line 3146
  • #16 g_main_context_iteration
    at gmain.c line 3207
  • #17 g_application_run
    at gapplication.c line 1496
  • #18 main
    at empathy-chat.c line 163

Comment 1 Philip Withnall 2012-05-02 22:21:18 UTC
This could only happen if tp_contact_get_identifier() is returning NULL, which the documentation says should never happen. I seem to remember Xavier fixing something like this in tp-glib a few weeks ago.

Does your version of tp-glib include http://cgit.freedesktop.org/telepathy/telepathy-glib/commit/?id=a75257708a4766a5e1fcbf19d1d7d5bf588eab91?
Comment 2 Guillaume Desmottes 2012-05-03 08:45:17 UTC
I do. I checked and the TpContact passed to tpf_persona_dup_for_contact() is not NULL and tp_contact_get_identifier() returns its id as expected.
Comment 3 Philip Withnall 2012-05-03 21:50:27 UTC
Created attachment 213417 [details] [review]
Initialise Tpf.PersonaStore._favourite_ids correctly

https://www.gitorious.org/folks/folks/commits/675292-initialise-favourite-ids

Sorry, I misread the warning in your initial comment. Of course it’s the HashSet which is null, not the contact’s ID.

This patch should fix it.
Comment 4 Guillaume Desmottes 2012-05-04 07:16:28 UTC
Review of attachment 213417 [details] [review]:

++

Didn't test if this was affecting the stable branch or not so please double check when merging.
Comment 5 Philip Withnall 2012-05-04 08:26:13 UTC
Comment on attachment 213417 [details] [review]
Initialise Tpf.PersonaStore._favourite_ids correctly

Merged to master. Doesn’t affect 0.6 at all, since it was introduced during the port to ContactList.

commit d71eabd2ee1fb2b5d6c266d35f20f6baccd4a23d
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Thu May 3 22:48:18 2012 +0100

    Bug 675292 — Assertion when joining IRC channel
    
    Correctly initialise Tpf.PersonaStore._favourite_ids on store construction,
    rather than on preparation. This prevents it being null at inopportune times.
    
    Closes: https://bugzilla.gnome.org/show_bug.cgi?id=675292

 NEWS                                          |    1 +
 backends/telepathy/lib/tpf-persona-store.vala |    7 ++++---
 2 files changed, 5 insertions(+), 3 deletions(-)
Comment 6 Travis Reitter 2012-05-04 16:21:54 UTC
Closing on the assumption that your commit message wasn't subterfuge.