From 57f1d381405028272e52d73a3b8291f370f4638a Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Wed, 8 Mar 2023 16:19:22 +0100 Subject: [PATCH] snprintf: add missing prototype for local replacement (#820) Should fix these warnings with MSVS 2013 and older: `agent.c(294): warning C4013: '_libssh2_snprintf' undefined; assuming extern returning int` Follow-up to 4cdf785cd313c3272d04c2ef7458a35d44533d8b. --- src/libssh2_priv.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/libssh2_priv.h b/src/libssh2_priv.h index f80d55d4..358421a0 100644 --- a/src/libssh2_priv.h +++ b/src/libssh2_priv.h @@ -136,6 +136,7 @@ #if !defined(HAVE_SNPRINTF) #define LIBSSH2_SNPRINTF #define snprintf _libssh2_snprintf +int _libssh2_snprintf(char *cp, size_t cp_max_len, const char *fmt, ...); #endif /* "inline" keyword is valid only with C++ engine! */