From 7f2049b0d5f75fdd6ee868aee9742597b26a2389 Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Tue, 13 Aug 2013 08:15:16 +0200 Subject: [PATCH] include: Add a MIN macro. --- include/libssh/priv.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/include/libssh/priv.h b/include/libssh/priv.h index 1c460f75..43f749bb 100644 --- a/include/libssh/priv.h +++ b/include/libssh/priv.h @@ -223,8 +223,9 @@ int decompress_buffer(ssh_session session,ssh_buffer buf, size_t maxlen); /* match.c */ int match_hostname(const char *host, const char *pattern, unsigned int len); - - +#ifndef MIN +#define MIN(a,b) ((a) < (b) ? (a) : (b)) +#endif /** Free memory space */ #define SAFE_FREE(x) do { if ((x) != NULL) {free(x); x=NULL;} } while(0)