From: Paul Mackerras Date: Tue, 20 Aug 2024 09:30:33 +0000 (+1000) Subject: plugins/winbind: Use fclose() to match with fdopen() X-Git-Tag: v2.5.1~21 X-Git-Url: https://git.ozlabs.org/?a=commitdiff_plain;h=7eb932ba780c8773ddb1fb20495d5b5e748837ff;p=ppp.git plugins/winbind: Use fclose() to match with fdopen() Having done fdopen() on a couple of file descriptors, we then need to use fclose() to close them rather than close(). Signed-off-by: Paul Mackerras --- diff --git a/pppd/plugins/winbind.c b/pppd/plugins/winbind.c index 7f930df..a3e5aa0 100644 --- a/pppd/plugins/winbind.c +++ b/pppd/plugins/winbind.c @@ -432,14 +432,14 @@ unsigned int run_ntlm_auth(const char *username, } /* parent */ - if (close(child_out[0]) == -1) { - close(child_in[1]); + if (fclose(pipe_out) == -1) { + fclose(pipe_in); notice("error closing pipe?!? for child OUT[0]"); return NOT_AUTHENTICATED; } /* parent */ - if (close(child_in[1]) == -1) { + if (fclose(pipe_in) == -1) { notice("error closing pipe?!? for child IN[1]"); return NOT_AUTHENTICATED; }