summaryrefslogtreecommitdiff
path: root/src/select.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2016-09-17 14:41:15 -0700
committerGitHub <noreply@github.com>2016-09-17 14:41:15 -0700
commit132156766770da8340138aab117cf7e37787403c (patch)
tree5f837949c367f435d947833c6f52e37473357ee6 /src/select.cc
parenta3b573e1107729e743c96da8ed9272361ba6ae31 (diff)
parentc193cc3a5b4dbf39e19744cf4d30e616298eaa86 (diff)
downloadfork-ledger-132156766770da8340138aab117cf7e37787403c.tar.gz
fork-ledger-132156766770da8340138aab117cf7e37787403c.tar.bz2
fork-ledger-132156766770da8340138aab117cf7e37787403c.zip
Merge pull request #466 from schmave/win-1
Fix build under msys32; add Appveyor continuous build
Diffstat (limited to 'src/select.cc')
-rw-r--r--src/select.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/select.cc b/src/select.cc
index 1c69b2bf..8e7786e6 100644
--- a/src/select.cc
+++ b/src/select.cc
@@ -145,14 +145,14 @@ value_t select_command(call_scope_t& args)
string thus_far = "";
std::size_t cols = 0;
-#if HAVE_IOCTL
+#ifdef HAVE_IOCTL
struct winsize ws;
#endif
if (report.HANDLED(columns_))
cols = lexical_cast<std::size_t>(report.HANDLER(columns_).value);
else if (const char * columns_env = std::getenv("COLUMNS"))
cols = lexical_cast<std::size_t>(columns_env);
-#if HAVE_IOCTL
+#ifdef HAVE_IOCTL
else if (ioctl(STDIN_FILENO, TIOCGWINSZ, &ws) != -1)
cols = ws.ws_col;
#endif