summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2022-08-30 10:56:03 +0000
committerLaurent Bercot <ska@appnovation.com>2022-08-30 10:56:03 +0000
commitd41fef5b74478b36787f387ed3f58099ac19c905 (patch)
tree85fd306c4e0cc2dd629443541e55d2d4758b0acf
parente6822833c65d31a498b9b543d2d4fd34d5be939d (diff)
downloads6-networking-d41fef5b74478b36787f387ed3f58099ac19c905.tar.xz
s6-tls[cd]: don't leak useless fd to the app
Signed-off-by: Laurent Bercot <ska@appnovation.com>
-rw-r--r--AUTHORS1
-rw-r--r--src/tls/s6tls_sync_and_exec_app.c1
2 files changed, 2 insertions, 0 deletions
diff --git a/AUTHORS b/AUTHORS
index fa18529..5c0f4f3 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -15,3 +15,4 @@ Thanks to:
Paul Jarc <prj@case.edu>
Colin Booth <colin@heliocat.net>
Amitai Schleier <schmonz@schmonz.com>
+ Petr Vaněk <arkamar@atlas.cz>
diff --git a/src/tls/s6tls_sync_and_exec_app.c b/src/tls/s6tls_sync_and_exec_app.c
index 5c0180c..4126ad6 100644
--- a/src/tls/s6tls_sync_and_exec_app.c
+++ b/src/tls/s6tls_sync_and_exec_app.c
@@ -28,5 +28,6 @@ void s6tls_sync_and_exec_app (char const *const *argv, int const p[4][2], pid_t
_exit(wait_estatus(wstat)) ;
}
if (r >= MAXENVSIZE) strerr_dief1x(101, "SSL data too large; recompile with a bigger MAXENVSIZE") ;
+ close(p[2][0]) ;
s6tls_clean_and_exec(argv, options, buf, r-1) ;
}