summaryrefslogtreecommitdiff
path: root/Source/Core/Common/CDUtils.cpp
diff options
context:
space:
mode:
authorLéo Lam <leo@leolam.fr>2019-11-09 21:10:16 +0100
committerGitHub <noreply@github.com>2019-11-09 21:10:16 +0100
commitf4e12f85bce7f0ad3c3fcc5d19d7db495600a41b (patch)
tree5960897f371699d1b107c4c7007d541fb8694d79 /Source/Core/Common/CDUtils.cpp
parent6cb60f8d364fc9887bfb4779993036d5554902a2 (diff)
parentea8a3059bff1693ea640777a3aeb0c31daf18951 (diff)
Merge pull request #8393 from CookiePLMonster/long-paths
Support Windows 10 long paths
Diffstat (limited to 'Source/Core/Common/CDUtils.cpp')
-rw-r--r--Source/Core/Common/CDUtils.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/Core/Common/CDUtils.cpp b/Source/Core/Common/CDUtils.cpp
index fb67d076c6..559ff0234f 100644
--- a/Source/Core/Common/CDUtils.cpp
+++ b/Source/Core/Common/CDUtils.cpp
@@ -26,6 +26,7 @@
#include <IOKit/storage/IOMedia.h>
#include <paths.h>
#else
+#include <climits>
#include <fcntl.h>
#include <sys/ioctl.h>
#include <sys/stat.h>
@@ -211,7 +212,7 @@ bool IsCDROMDevice(std::string device)
#ifndef _WIN32
// Resolve symbolic links. This allows symbolic links to valid
// drives to be passed from the command line with the -e flag.
- char resolved_path[MAX_PATH];
+ char resolved_path[PATH_MAX];
char* devname = realpath(device.c_str(), resolved_path);
if (!devname)
return false;