1
0
mirror of https://github.com/libssh2/libssh2.git synced 2025-10-26 02:17:35 +03:00

NULL check before calling session_handshake

This commit is contained in:
Will Cosgrove
2022-04-11 09:46:52 -07:00
committed by GitHub
parent b95e758239
commit 3489ee9a6f

View File

@@ -61,7 +61,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
libssh2_session_set_blocking(session, 1);
}
if(libssh2_session_handshake(session, socket_fds[0])) {
if(session && libssh2_session_handshake(session, socket_fds[0])) {
goto EXIT_LABEL;
}