summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2013-09-26 23:00:19 +0200
committerGravatar Martin Szulecki2013-09-26 23:00:19 +0200
commitc68efda6ef497fa00307b9478c9f3d818e540f51 (patch)
tree279e6d42c9034a8974b1ca580b8c03426e7a6f82 /tools
parente6a122ac360e8293da09fcf9baff0f37ad0d58a3 (diff)
downloadlibirecovery-c68efda6ef497fa00307b9478c9f3d818e540f51.tar.gz
libirecovery-c68efda6ef497fa00307b9478c9f3d818e540f51.tar.bz2
irecovery: Define sleep() for WIN32
Diffstat (limited to 'tools')
-rw-r--r--tools/irecovery.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/irecovery.c b/tools/irecovery.c
index 8e2138c..5c82a00 100644
--- a/tools/irecovery.c
+++ b/tools/irecovery.c
@@ -26,6 +26,12 @@
#include <readline/readline.h>
#include <readline/history.h>
+#ifdef WIN32
+#ifndef sleep
+#define sleep(n) Sleep(1000 * n)
+#endif
+#endif
+
#define FILE_HISTORY_PATH ".irecovery"
#define debug(...) if(verbose) fprintf(stderr, __VA_ARGS__)