From 79542ff4f0e89d531c0a45773f447b8ade2a39d2 Mon Sep 17 00:00:00 2001 From: Jean-Claude Michelou Date: Thu, 13 Sep 2018 18:57:10 +0200 Subject: [PATCH] examples: fixes the missing macro S_ISDIR The Windows build need the S_ISDIR macro here. --- examples/client.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/examples/client.c b/examples/client.c index 105aff4e..e0a29c71 100644 --- a/examples/client.c +++ b/examples/client.c @@ -1077,6 +1077,10 @@ setup_pki(void) { return &dtls_pki; } +#ifdef _WIN32 +#define S_ISDIR(x) (((x) & S_IFMT) == S_IFDIR) +#endif + static coap_session_t * get_session( coap_context_t *ctx,