Renamed stanza->stream for id callback
This commit is contained in:
@@ -48,8 +48,8 @@ stbbr_auth_passwd(char *password)
|
||||
}
|
||||
|
||||
int
|
||||
stbbr_for(char *id, char *stanza)
|
||||
stbbr_for(char *id, char *stream)
|
||||
{
|
||||
prime_for(id, stanza);
|
||||
prime_for(id, stream);
|
||||
return 1;
|
||||
}
|
||||
|
||||
@@ -19,13 +19,13 @@ prime_get_passwd(void)
|
||||
}
|
||||
|
||||
void
|
||||
prime_for(char *id, char *stanza)
|
||||
prime_for(char *id, char *stream)
|
||||
{
|
||||
if (!idstubs) {
|
||||
idstubs = g_hash_table_new_full(g_str_hash, g_str_equal, free, free);
|
||||
}
|
||||
|
||||
g_hash_table_insert(idstubs, strdup(id), strdup(stanza));
|
||||
g_hash_table_insert(idstubs, strdup(id), strdup(stream));
|
||||
}
|
||||
|
||||
char*
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
void prime_required_passwd(char *password);
|
||||
char* prime_get_passwd(void);
|
||||
|
||||
int prime_for(char *id, char *stanza);
|
||||
int prime_for(char *id, char *stream);
|
||||
char* prime_get_for(const char *id);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -169,11 +169,11 @@ auth_callback(XMPPStanza *stanza, XMPPClient *client)
|
||||
void
|
||||
id_callback(const char *id, XMPPClient *client)
|
||||
{
|
||||
char *stanza_ret = prime_get_for(id);
|
||||
if (stanza_ret) {
|
||||
char *stream = prime_get_for(id);
|
||||
if (stream) {
|
||||
log_print_chars("\n");
|
||||
log_println("--> ID callback fired for '%s'", id);
|
||||
send_to(client, stanza_ret);
|
||||
send_to(client, stream);
|
||||
log_print("RECV: ");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user