summaryrefslogtreecommitdiff
path: root/src/stls/stls_s6tlsd.c
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2016-12-01 02:24:09 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2016-12-01 02:24:09 +0000
commit880f2a22304b393b43397c3ec8de83052a2584ce (patch)
tree23eca19438ee116cca0af840f709c4fd63bcd95b /src/stls/stls_s6tlsd.c
parentcc08be523a2a647a999dcf82dcce9dee62b4162c (diff)
downloads6-networking-880f2a22304b393b43397c3ec8de83052a2584ce.tar.xz
Fix several bugs in stls, make the engine work
Diffstat (limited to 'src/stls/stls_s6tlsd.c')
-rw-r--r--src/stls/stls_s6tlsd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/stls/stls_s6tlsd.c b/src/stls/stls_s6tlsd.c
index 1506556..64cf01f 100644
--- a/src/stls/stls_s6tlsd.c
+++ b/src/stls/stls_s6tlsd.c
@@ -78,14 +78,14 @@ int stls_s6tlsd (char const *const *argv, char const *const *envp, tain_t const
if (tls_accept_fds(ctx, &cctx, fds[2], fds[3]) < 0)
diectx(97, ctx, "tls_accept_fds") ;
-
tls_free(ctx) ;
+ if (tls_handshake(cctx) < 0) diectx(97, cctx, "perform SSL handshake") ;
{
int wstat ;
int r = stls_run(cctx, fds, verbosity, options, tto) ;
if (r < 0) strerr_diefu1sys(111, "run SSL engine") ;
- else if (r) diectx(98, cctx, "establish or maintain SSL connection to peer") ;
+ else if (r) diectx(98, cctx, "maintain SSL connection to peer") ;
if (wait_pid(pid, &wstat) < 0) strerr_diefu1sys(111, "wait_pid") ;
return wait_estatus(wstat) ;
}