aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/jabber/jabber.h
diff options
context:
space:
mode:
authorSven Moritz Hallberg <pesco@khjk.org>2010-06-03 13:00:45 +0200
committerSven Moritz Hallberg <pesco@khjk.org>2010-06-03 13:00:45 +0200
commit814aa52228c7cad1d036c1a6dc5ea03cce61c048 (patch)
tree7db06b9191f00b086f25789a0a040d15cef580cf /protocols/jabber/jabber.h
parent5f8ab6a9adf09ea7c07f728227bdb6d3953588f1 (diff)
parentf4bcc223fea70de8555bbc4d2caf48e0476c0e13 (diff)
merge in bitlbee 1.2.6
Diffstat (limited to 'protocols/jabber/jabber.h')
-rw-r--r--protocols/jabber/jabber.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/protocols/jabber/jabber.h b/protocols/jabber/jabber.h
index 8e3bf036..40cf3957 100644
--- a/protocols/jabber/jabber.h
+++ b/protocols/jabber/jabber.h
@@ -107,6 +107,13 @@ struct jabber_cache_entry
jabber_cache_event func;
};
+/* Somewhat messy data structure: We have a hash table with the bare JID as
+ the key and the head of a struct jabber_buddy list as the value. The head
+ is always a bare JID. If the JID has other resources (often the case,
+ except for some transports that don't support multiple resources), those
+ follow. In that case, the bare JID at the beginning doesn't actually
+ refer to a real session and should only be used for operations that
+ support incomplete JIDs. */
struct jabber_buddy
{
char *bare_jid;
@@ -120,7 +127,7 @@ struct jabber_buddy
struct jabber_away_state *away_state;
char *away_message;
- time_t last_act;
+ time_t last_msg;
jabber_buddy_flags_t flags;
struct jabber_buddy *next;
@@ -208,6 +215,8 @@ typedef enum
GET_BUDDY_CREAT = 1, /* Try to create it, if necessary. */
GET_BUDDY_EXACT = 2, /* Get an exact match (only makes sense with bare JIDs). */
GET_BUDDY_FIRST = 4, /* No selection, simply get the first resource for this JID. */
+ GET_BUDDY_BARE = 8, /* Get the bare version of the JID (possibly inexistent). */
+ GET_BUDDY_BARE_OK = 16, /* Allow returning a bare JID if that seems better. */
} get_buddy_flags_t;
struct jabber_error