From: Ian Jackson Date: Thu, 11 Aug 2022 19:32:49 +0000 (+0100) Subject: prefork-interp: fixes and tests X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=chiark-utils.git;a=commitdiff_plain;h=c884a207b6df241e8bf77df0d3e0498eb099a72c prefork-interp: fixes and tests Signed-off-by: Ian Jackson --- diff --git a/cprogs/prefork-interp.c b/cprogs/prefork-interp.c index 7e35087..916fdef 100644 --- a/cprogs/prefork-interp.c +++ b/cprogs/prefork-interp.c @@ -304,7 +304,7 @@ static FILE *connect_existing(void) { return call_sock; x_garbage: - fclose(call_sock); + if (call_sock) fclose(call_sock); if (fd >= 0) close(fd); return 0; }