Skip to content

Commit

Permalink
Whitespace in trust router
Browse files Browse the repository at this point in the history
  • Loading branch information
arr2036 committed Sep 28, 2015
1 parent b0399c2 commit 98b5d5b
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions src/modules/rlm_realm/trustrouter.c
Expand Up @@ -42,7 +42,7 @@ struct resp_opaque {
};


bool tr_init(void)
bool tr_init(void)
{
if (global_tidc) return true;

Expand Down Expand Up @@ -108,7 +108,7 @@ static fr_tls_server_conf_t *construct_tls(TIDC_INSTANCE *inst,
if (tls) talloc_free(tls);
return NULL;
}

static char *build_pool_name(TALLOC_CTX *ctx, TID_RESP *resp)
{
size_t index, sa_len, sl;
Expand Down Expand Up @@ -253,7 +253,7 @@ static void tr_response_func( TIDC_INSTANCE *inst,
}
return;
}

if (!nr) {
nr = talloc_zero(NULL, REALM);
if (!nr) goto error;
Expand All @@ -280,7 +280,7 @@ static void tr_response_func( TIDC_INSTANCE *inst,

opaque->output_realm = nr;
return;

error:
if (nr && !opaque->orig_realm) {
talloc_free(nr);
Expand Down Expand Up @@ -315,7 +315,7 @@ static bool update_required(REALM const *r)
/*
* These values don't make sense.
*/
if ((server->last_packet_recv > (now + 5)) ||
if ((server->last_packet_recv > (now + 5)) ||
(server->last_failed_open > (now + 5))) {
continue;
}
Expand All @@ -340,7 +340,7 @@ static bool update_required(REALM const *r)
return true;
}



REALM *tr_query_realm(REQUEST *request, char const *realm,
char const *community,
Expand Down Expand Up @@ -377,7 +377,7 @@ REALM *tr_query_realm(REQUEST *request, char const *realm,
talloc_free(cookie.fr_realm_name);
return cookie.orig_realm;
}

/* Set-up TID connection */
DEBUG2("Opening TIDC connection to %s:%u", trustrouter, port);

Expand All @@ -389,8 +389,8 @@ REALM *tr_query_realm(REQUEST *request, char const *realm,
}

/* Send a TID request */
rcode = tidc_send_request(global_tidc, conn, gssctx, (char *)rprealm,
(char *) realm, (char *)community,
rcode = tidc_send_request(global_tidc, conn, gssctx, (char *)rprealm,
(char *) realm, (char *)community,
&tr_response_func, &cookie);
if (rcode < 0) {
/* Handle error */
Expand All @@ -400,7 +400,7 @@ REALM *tr_query_realm(REQUEST *request, char const *realm,
if (cookie.result != TID_SUCCESS) {
DEBUG2("TID response is error, rc = %d: %s.\n", cookie.result,
cookie.err_msg?cookie.err_msg:"(NO ERROR TEXT)");
if (cookie.err_msg)
if (cookie.err_msg)
pair_make_reply("Reply-Message", cookie.err_msg, T_OP_SET);
pair_make_reply("Error-Cause", "502", T_OP_SET); /*proxy unroutable*/
}
Expand Down

0 comments on commit 98b5d5b

Please sign in to comment.