summaryrefslogtreecommitdiff
path: root/src/common/utils.h
diff options
context:
space:
mode:
authorKenpachi Developer <Kenpachi.Developer@gmx.de>2020-02-08 00:34:29 +0100
committerHaru <haru@dotalux.com>2020-02-09 20:23:14 +0100
commit01e854b8d27e22c5dc7fb35726ec8579e7120eeb (patch)
tree40e341a32633625c83d53abfbee3eea5bb315ded /src/common/utils.h
parentce21c1e9361e04391dc41463af24d5eb0c493bd1 (diff)
downloadhercules-01e854b8d27e22c5dc7fb35726ec8579e7120eeb.tar.gz
hercules-01e854b8d27e22c5dc7fb35726ec8579e7120eeb.tar.bz2
hercules-01e854b8d27e22c5dc7fb35726ec8579e7120eeb.tar.xz
hercules-01e854b8d27e22c5dc7fb35726ec8579e7120eeb.zip
Define MAX_DIR_PATH for WIN32, too
Diffstat (limited to 'src/common/utils.h')
-rw-r--r--src/common/utils.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/common/utils.h b/src/common/utils.h
index b160d3651..3e0d73e40 100644
--- a/src/common/utils.h
+++ b/src/common/utils.h
@@ -31,6 +31,14 @@
/* [HCache] 1-byte key to ensure our method is the latest, we can modify to ensure the method matches */
#define HCACHE_KEY 'k'
+#ifndef MAX_DIR_PATH
+#ifdef WIN32
+#define MAX_DIR_PATH MAX_PATH
+#else
+#define MAX_DIR_PATH 2048
+#endif
+#endif
+
//Caps values to min/max
#define cap_value(a, min, max) (((a) >= (max)) ? (max) : ((a) <= (min)) ? (min) : (a))