Skip to content

Commit 3c38346

Browse files
committed
close options.h header after reading
1 parent 0e6e405 commit 3c38346

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/wolfssl/_build_ffi.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,10 @@
2828

2929
# open <wolfssl/options.h> header to parse for #define's
3030
# This will throw a FileNotFoundError if not able to find options.h
31-
optionsHeader = wolfssl_inc_path() + "/wolfssl/options.h"
32-
optionsHeaderStr = open(optionsHeader, 'r').read()
31+
optionsHeaderPath = wolfssl_inc_path() + "/wolfssl/options.h"
32+
optionsHeader = open(optionsHeaderPath, 'r')
33+
optionsHeaderStr = optionsHeader.read()
34+
optionsHeader.close()
3335

3436
# require HAVE_SNI (--enable-sni) in native lib
3537
if '#define HAVE_SNI' not in optionsHeaderStr:

0 commit comments

Comments
 (0)