Commit 0a578b18 authored by Pekka Pessi's avatar Pekka Pessi

tport/tport_type_tls.c: fixed whitespace

darcs-hash:20081127130818-db55f-f1bbd210f7f4665895b7d3837d52fef49c1dd1b3.gz
parent 1785cd1c
......@@ -54,11 +54,11 @@
#include "tport_tls.h"
static int tport_tls_init_primary(tport_primary_t *,
tp_name_t tpn[1],
tp_name_t tpn[1],
su_addrinfo_t *, tagi_t const *,
char const **return_culprit);
static int tport_tls_init_client(tport_primary_t *,
tp_name_t tpn[1],
tp_name_t tpn[1],
su_addrinfo_t *, tagi_t const *,
char const **return_culprit);
static int tport_tls_init_master(tport_primary_t *pri,
......@@ -182,7 +182,7 @@ static int tport_tls_init_master(tport_primary_t *pri,
homedir = "";
path = tbf = su_sprintf(autohome, "%s/.sip/auth", homedir);
}
if (path) {
ti.verify_peer = tls_verify;
ti.verify_depth = 2;
......@@ -252,7 +252,7 @@ static void tport_tls_deinit_secondary(tport_t *self)
tport_tls_t *tlstp = (tport_tls_t *)self;
/* XXX - PPe: does the tls_shutdown zap everything but socket? */
if (tlstp->tlstp_context != NULL)
if (tlstp->tlstp_context != NULL)
tls_free(tlstp->tlstp_context);
tlstp->tlstp_context = NULL;
......@@ -281,16 +281,16 @@ int tport_tls_set_events(tport_t const *self)
int mask = tls_events(tlstp->tlstp_context, self->tp_events);
SU_DEBUG_7(("%s(%p): logical events%s%s real%s%s\n",
"tport_tls_set_events", (void *)self,
"tport_tls_set_events", (void *)self,
(self->tp_events & SU_WAIT_IN) ? " IN" : "",
(self->tp_events & SU_WAIT_OUT) ? " OUT" : "",
(mask & SU_WAIT_IN) ? " IN" : "",
(mask & SU_WAIT_OUT) ? " OUT" : ""));
return
su_root_eventmask(self->tp_master->mr_root,
self->tp_index,
self->tp_socket,
su_root_eventmask(self->tp_master->mr_root,
self->tp_index,
self->tp_socket,
mask);
}
......@@ -311,7 +311,7 @@ int tport_tls_events(tport_t *self, int events)
else if (ret < 0)
tport_error_report(self, errno, NULL);
}
if ((self->tp_events & SU_WAIT_IN) && !self->tp_closed) {
for (;;) {
ret = tls_want_read(tlstp->tlstp_context, events);
......@@ -348,15 +348,15 @@ int tport_tls_events(tport_t *self, int events)
return 0;
SU_DEBUG_7(("%s(%p): logical events%s%s real%s%s\n",
"tport_tls_events", (void *)self,
"tport_tls_events", (void *)self,
(events & SU_WAIT_IN) ? " IN" : "",
(events & SU_WAIT_OUT) ? " OUT" : "",
(mask & SU_WAIT_IN) ? " IN" : "",
(mask & SU_WAIT_OUT) ? " OUT" : ""));
su_root_eventmask(self->tp_master->mr_root,
self->tp_index,
self->tp_socket,
su_root_eventmask(self->tp_master->mr_root,
self->tp_index,
self->tp_socket,
mask);
return 0;
......@@ -365,12 +365,12 @@ int tport_tls_events(tport_t *self, int events)
/** Receive data from TLS.
*
* @retval -1 error
* @retval 0 end-of-stream
* @retval 0 end-of-stream
* @retval 1 normal receive
* @retval 2 incomplete recv, recv again
*
*
*/
static
static
int tport_tls_recv(tport_t *self)
{
tport_tls_t *tlstp = (tport_tls_t *)self;
......@@ -411,7 +411,7 @@ int tport_tls_recv(tport_t *self)
memcpy(iovec[i].mv_base, tls_buf + n, m);
n += m;
}
assert(N == n);
/* Write the received data to the message dump file */
......@@ -453,7 +453,7 @@ ssize_t tport_tls_send(tport_t const *self,
for (i = 0; i < iovlen; i = j) {
#if 0
nerror = tls_write(tlstp->tlstp_context,
nerror = tls_write(tlstp->tlstp_context,
iov[i].siv_base,
m = iov[i].siv_len);
j = i + 1;
......@@ -464,7 +464,7 @@ ssize_t tport_tls_send(tport_t const *self,
if (i + 1 == iovlen)
buf = NULL; /* Don't bother copying single chunk */
if (buf &&
if (buf &&
(char *)iov[i].siv_base - buf < TLSBUFSIZE &&
(char *)iov[i].siv_base - buf >= 0) {
tlsbufsize = buf + TLSBUFSIZE - (char *)iov[i].siv_base;
......@@ -487,8 +487,8 @@ ssize_t tport_tls_send(tport_t const *self,
nerror = tls_write(tlstp->tlstp_context, buf, m);
#endif
SU_DEBUG_9(("tport_tls_writevec: vec %p %p %lu ("MOD_ZD")\n",
(void *)tlstp->tlstp_context, (void *)iov[i].siv_base, (LU)iov[i].siv_len,
SU_DEBUG_9(("tport_tls_writevec: vec %p %p %lu ("MOD_ZD")\n",
(void *)tlstp->tlstp_context, (void *)iov[i].siv_base, (LU)iov[i].siv_len,
nerror));
if (nerror == -1) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment