[Bug 32444] New: Tidy up GabblePresenceCache

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Dec 16 18:08:41 CET 2010


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

           Summary: Tidy up GabblePresenceCache
           Product: Telepathy
           Version: git master
          Platform: Other
        OS/Version: All
            Status: NEW
          Keywords: love
          Severity: enhancement
          Priority: low
         Component: gabble
        AssignedTo: telepathy-bugs at lists.freedesktop.org
        ReportedBy: will.thompson at collabora.co.uk
         QAContact: telepathy-bugs at lists.freedesktop.org


connection_iq_disco_cb() contains the following comment:

      /* Otherwise, is it one of the caps bundles we advertise? These are not
       * just shoved into the cache with gabble_presence_cache_add_own_caps()
       * because capabilities_get_features() always includes a few bonus
       * features...
       */

capabilities_get_features() no longer exists; there's no reason why we can't
serve the responses to Google Talk-compatibility bundles like "voice-v1" from
the same place as we serve our other caps responses.

So I guess the thing to do would be to replace the calls to
gabble_presence_cache_add_bundle_caps() at the end of
gabble_presence_cache_add_bundles() with calls to
gabble_presence_cache_add_own_caps(), and add one for pmuc-v1 which is just an
empty caps set. This would let us simplify connection_iq_disco_cb().

We could get some further simplification by ensuring that our default identity
is in the caps cache entry for our own caps nodes, rather than depending on the
same one being hard-coded in caps_hash_compute_from_self_presence() and
connection_iq_disco_cb().

(In general, the presence cache is fertile ground for refactoring by interested
parties.)

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



More information about the telepathy-bugs mailing list