@abh3 requested changes on this pull request.
Somewhat minor issue and a suggestion to carry through the needed change to another part of the code. I was wondering why we are playing so many games with fdopen(), Would a single open stream suffice for this? I'm not asking to change it just curious why this is necessary.
In src/XrdTls/XrdTlsTempCA.cc:
> @@ -217,6 +234,26 @@ bool CRLSet::atLeastOneValidCRLFound() const { return m_atLeastOneValidCRLFound; } +bool CRLSet::processCRLWithCriticalExt() { + // Don't open the output file if not necessary + if(!m_crls_critical_extension.empty()) { + file_smart_ptr outputfp(fdopen(dup(m_output_fd), "w"), &fclose);
Please use XrdSysFD_Dup() instead of dup() to avoid FD leakage (see line 104 in the original file). This should also be corrected in line 180 that somehow missed using XrdSysFD_Dup() in CRLSet::processFile(). I know it's not technically part of this patch but it should be corrected either via this patch or with an addition pull request (technically cleaner) so that we don't forget.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.
Use REPLY-ALL to reply to list
To unsubscribe from the XROOTD-DEV list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=XROOTD-DEV&A=1