Applied coding style to src/otr/

This commit is contained in:
James Booth
2015-10-25 22:40:09 +00:00
parent afbd2693cd
commit 894fa355e8
5 changed files with 63 additions and 64 deletions

View File

@@ -63,13 +63,13 @@ otr_userstate(void)
return user_state;
}
OtrlMessageAppOps *
OtrlMessageAppOps*
otr_messageops(void)
{
return &ops;
}
GHashTable *
GHashTable*
otr_smpinitators(void)
{
return smp_initiators;
@@ -146,13 +146,13 @@ cb_gone_secure(void *opdata, ConnContext *context)
ui_gone_secure(context->username, otr_is_trusted(context->username));
}
char *
char*
otr_libotr_version(void)
{
return OTRL_VERSION;
}
char *
char*
otr_start_query(void)
{
return otrlib_start_query();
@@ -274,7 +274,7 @@ otr_on_connect(ProfAccount *account)
}
char*
otr_on_message_recv(const char * const barejid, const char * const resource, const char * const message, gboolean *decrypted)
otr_on_message_recv(const char *const barejid, const char *const resource, const char *const message, gboolean *decrypted)
{
prof_otrpolicy_t policy = otr_get_policy(barejid);
char *whitespace_base = strstr(message, OTRL_MESSAGE_TAG_BASE);
@@ -314,7 +314,7 @@ otr_on_message_recv(const char * const barejid, const char * const resource, con
}
gboolean
otr_on_message_send(ProfChatWin *chatwin, const char * const message)
otr_on_message_send(ProfChatWin *chatwin, const char *const message)
{
char *id = NULL;
prof_otrpolicy_t policy = otr_get_policy(chatwin->barejid);
@@ -451,8 +451,8 @@ otr_key_loaded(void)
return data_loaded;
}
char *
otr_tag_message(const char * const msg)
char*
otr_tag_message(const char *const msg)
{
GString *otr_message = g_string_new(msg);
g_string_append(otr_message, OTRL_MESSAGE_TAG_BASE);
@@ -464,7 +464,7 @@ otr_tag_message(const char * const msg)
}
gboolean
otr_is_secure(const char * const recipient)
otr_is_secure(const char *const recipient)
{
ConnContext *context = otrlib_context_find(user_state, recipient, jid);
@@ -480,7 +480,7 @@ otr_is_secure(const char * const recipient)
}
gboolean
otr_is_trusted(const char * const recipient)
otr_is_trusted(const char *const recipient)
{
ConnContext *context = otrlib_context_find(user_state, recipient, jid);
@@ -506,7 +506,7 @@ otr_is_trusted(const char * const recipient)
}
void
otr_trust(const char * const recipient)
otr_trust(const char *const recipient)
{
ConnContext *context = otrlib_context_find(user_state, recipient, jid);
@@ -530,7 +530,7 @@ otr_trust(const char * const recipient)
}
void
otr_untrust(const char * const recipient)
otr_untrust(const char *const recipient)
{
ConnContext *context = otrlib_context_find(user_state, recipient, jid);
@@ -554,7 +554,7 @@ otr_untrust(const char * const recipient)
}
void
otr_smp_secret(const char * const recipient, const char *secret)
otr_smp_secret(const char *const recipient, const char *secret)
{
ConnContext *context = otrlib_context_find(user_state, recipient, jid);
@@ -578,7 +578,7 @@ otr_smp_secret(const char * const recipient, const char *secret)
}
void
otr_smp_question(const char * const recipient, const char *question, const char *answer)
otr_smp_question(const char *const recipient, const char *question, const char *answer)
{
ConnContext *context = otrlib_context_find(user_state, recipient, jid);
@@ -595,7 +595,7 @@ otr_smp_question(const char * const recipient, const char *question, const char
}
void
otr_smp_answer(const char * const recipient, const char *answer)
otr_smp_answer(const char *const recipient, const char *answer)
{
ConnContext *context = otrlib_context_find(user_state, recipient, jid);
@@ -612,12 +612,12 @@ otr_smp_answer(const char * const recipient, const char *answer)
}
void
otr_end_session(const char * const recipient)
otr_end_session(const char *const recipient)
{
otrlib_end_session(user_state, recipient, jid, &ops);
}
char *
char*
otr_get_my_fingerprint(void)
{
char fingerprint[45];
@@ -627,8 +627,8 @@ otr_get_my_fingerprint(void)
return result;
}
char *
otr_get_their_fingerprint(const char * const recipient)
char*
otr_get_their_fingerprint(const char *const recipient)
{
ConnContext *context = otrlib_context_find(user_state, recipient, jid);
@@ -643,7 +643,7 @@ otr_get_their_fingerprint(const char * const recipient)
}
prof_otrpolicy_t
otr_get_policy(const char * const recipient)
otr_get_policy(const char *const recipient)
{
char *account_name = jabber_get_account_name();
ProfAccount *account = accounts_get_account(account_name);
@@ -695,8 +695,8 @@ otr_get_policy(const char * const recipient)
return result;
}
char *
otr_encrypt_message(const char * const to, const char * const message)
char*
otr_encrypt_message(const char *const to, const char *const message)
{
char *newmessage = NULL;
gcry_error_t err = otrlib_encrypt_message(user_state, &ops, jid, to, message, &newmessage);
@@ -716,8 +716,8 @@ _otr_tlv_free(OtrlTLV *tlvs)
}
}
char *
otr_decrypt_message(const char * const from, const char * const message, gboolean *decrypted)
char*
otr_decrypt_message(const char *const from, const char *const message, gboolean *decrypted)
{
char *newmessage = NULL;
OtrlTLV *tlvs = NULL;