From f9a99530ffc176599c28d63907c89fe2caf7d964 Mon Sep 17 00:00:00 2001
From: Pavel Pimenov <pavel.pimenov@gmail.com>
Date: Fri, 7 Feb 2014 11:02:12 +0400
Subject: [PATCH] Add #ifndef MONGOOSE_NO_FILESYSTEM

---
 mongoose.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/mongoose.c b/mongoose.c
index 55714c1e1..d5c061263 100644
--- a/mongoose.c
+++ b/mongoose.c
@@ -443,6 +443,7 @@ void *mg_start_thread(void *(*f)(void *), void *p) {
 #endif  // MONGOOSE_NO_THREADS
 
 #ifdef _WIN32
+#ifndef MONGOOSE_NO_FILESYSTEM
 // Encode 'path' which is assumed UTF-8 string, into UNICODE string.
 // wbuf and wbuf_len is a target buffer and its length.
 static void to_wchar(const char *path, wchar_t *wbuf, size_t wbuf_len) {
@@ -487,6 +488,7 @@ static int mg_open(const char *path, int flag) {
   return _wopen(wpath, flag);
 }
 #endif
+#endif // MONGOOSE_NO_FILESYSTEM
 
 static void set_close_on_exec(int fd) {
 #ifdef _WIN32
-- 
GitLab