Skip to content

Commit 0c996ec

Browse files
panvaaduh95
authored andcommitted
build: handle malformed OpenSSL macros
A missing OPENSSL_VERSION_NUMBER macro raises TypeError while the configure logic attempts to slice None. Treat that like the other version detection failures so configure warns and records version 0. Signed-off-by: Filip Skokan <panva.ip@gmail.com> PR-URL: #64982 Reviewed-By: Richard Lau <richard.lau@ibm.com> Reviewed-By: Aviv Keller <me@aviv.sh>
1 parent c2b1514 commit 0c996ec

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

configure.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1517,7 +1517,7 @@ def get_openssl_version(o):
15171517

15181518
return version_number
15191519

1520-
except (OSError, ValueError, subprocess.SubprocessError) as e:
1520+
except (OSError, TypeError, ValueError, subprocess.SubprocessError) as e:
15211521
warn(f'Failed to determine OpenSSL version from header: {e}')
15221522
return 0
15231523

0 commit comments

Comments
 (0)