summaryrefslogtreecommitdiff
path: root/tools/minicargo/path.cpp
diff options
context:
space:
mode:
authorJohn Hodge <tpg@mutabah.net>2017-08-31 17:35:29 +0800
committerJohn Hodge <tpg@mutabah.net>2017-08-31 17:35:29 +0800
commit43a9adaef989a8bed5f8fafeef78555df0bd8fb0 (patch)
tree6eedfe5af1e1a4a3fd0ae18cf6cb94713cfbb260 /tools/minicargo/path.cpp
parentbb4c5f2b93b4188f8cf574a782303bc05756b230 (diff)
downloadmrust-43a9adaef989a8bed5f8fafeef78555df0bd8fb0.tar.gz
Misc - Windows compile fixes
Diffstat (limited to 'tools/minicargo/path.cpp')
-rw-r--r--tools/minicargo/path.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/minicargo/path.cpp b/tools/minicargo/path.cpp
index 93281e0f..12e505bb 100644
--- a/tools/minicargo/path.cpp
+++ b/tools/minicargo/path.cpp
@@ -2,6 +2,7 @@
*/
#include "path.h"
#if _WIN32
+# include <Windows.h>
#else
# include <unistd.h> // getcwd/chdir
#endif
@@ -41,6 +42,8 @@ helpers::path helpers::path::to_absolute() const
return *this;
#if _WIN32
+ char cwd[1024];
+ GetCurrentDirectoryA(sizeof(cwd), cwd);
#else
char cwd[1024];
if( !getcwd(cwd, sizeof(cwd)) )