summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/libutil.cc
diff options
context:
space:
mode:
Diffstat (limited to 'crawl-ref/source/libutil.cc')
-rw-r--r--crawl-ref/source/libutil.cc16
1 files changed, 15 insertions, 1 deletions
diff --git a/crawl-ref/source/libutil.cc b/crawl-ref/source/libutil.cc
index 5246c2704d..096eeffc8a 100644
--- a/crawl-ref/source/libutil.cc
+++ b/crawl-ref/source/libutil.cc
@@ -140,7 +140,7 @@ int unmangle_direction_keys(int keyin, int km)
// the shell can do damage with.
bool shell_safe(const char *file)
{
- int match = strcspn(file, "`$*?|><&\n");
+ int match = strcspn(file, "\\`$*?|><&\n!");
return !(match >= 0 && file[match]);
}
@@ -302,6 +302,20 @@ int c_getch()
#endif
}
+// Wrapper around gotoxy that can draw a fake cursor for Unix terms where
+// cursoring over darkgray or black causes problems.
+void cursorxy(int x, int y)
+{
+#ifdef UNIX
+ if (Options.use_fake_cursor)
+ fakecursorxy(x, y);
+ else
+ gotoxy(x, y);
+#else
+ gotoxy(x, y);
+#endif
+}
+
// cprintf that knows how to wrap down lines (primitive, but what the heck)
int wrapcprintf( int wrapcol, const char *s, ... )
{