[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] winlocks: Include stdlib.h to avoid crash in Windows
[Thread Prev] | [Thread Next]
- Subject: [PATCH] winlocks: Include stdlib.h to avoid crash in Windows
- From: Chris Townsend <Christopher.Townsend@xxxxxxxxxxxxx>
- Reply-to: libssh@xxxxxxxxxx
- Date: Wed, 10 Mar 2021 14:54:13 -0500
- To: libssh@xxxxxxxxxx
Due to the missing include, the compiler makes assumptions and leads to a crash in ssh_mutex_lock() during runtime. Signed-off-by: Chris Townsend <christopher.townsend@xxxxxxxxxxxxx> --- src/threads/winlocks.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/threads/winlocks.c b/src/threads/winlocks.c index a1799531..da600418 100644 --- a/src/threads/winlocks.c +++ b/src/threads/winlocks.c @@ -26,6 +26,7 @@ #include <windows.h> #include <winbase.h> #include <errno.h> +#include <stdlib.h> static int ssh_winlock_mutex_init (void **priv) {
Archive administrator: postmaster@lists.cynapses.org