Skip to content
Commit a1a20f02 authored by Florian Weimer's avatar Florian Weimer
Browse files

resolv: Fix file handle leak in __resolv_conf_load [BZ #25429]



res_vinit_1 did not close the stream on errors, only on success.
This change moves closing the stream to __resolv_conf_load, for both
the success and error cases.

Fixes commit 89f187a4 ("resolv: Use
getline for configuration file reading in res_vinit_1") and commit
3f853f22 ("resolv: Lift domain search
list limits [BZ #19569] [BZ #21475]"), where memory allocation was
introduced into res_vinit_1.

Reviewed-by: default avatarAdhemerval Zanella <adhemerval.zanella@linaro.org>
parent 9642b85f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment