diff --git a/ChangeLog b/ChangeLog
index 7ac85f53ce3b6274689147003faab0ea02c660d2..b359c2779f683b9fca1eb3efd89ff2ad83fbfc82 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -6,6 +6,7 @@
 	an addition a full refresh is needed (for multiline-regexes' sake),
 	instead of doing it always.
 	* src/color.c (reset_multis): Abort when having no multiline regexes.
+	* src/nano.c (do_input): A functionless shortcut should be impossible.
 
 2016-01-02  Benno Schulenberg  <bensberg@justemail.net>
 	* src/text.c (do_spell, do_formatter): Plug three tiny memory leaks.
diff --git a/src/nano.c b/src/nano.c
index 20ac4adeacd2e55bf3e9587c944332e55913e2d0..45fc33e28cce20b7e8868c8e2d85350f06368231 100644
--- a/src/nano.c
+++ b/src/nano.c
@@ -1712,7 +1712,11 @@ int do_input(bool allow_funcs)
 		)
 		preserve = TRUE;
 
-	    if (s->scfunc != 0) {
+	    if (s->scfunc == NULL) {
+		statusbar("Internal error: shortcut without function!");
+		return ERR;
+	    }
+	    {
 		const subnfunc *f = sctofunc((sc *) s);
 		if (ISSET(VIEW_MODE) && f && !f->viewok)
 		    print_view_warning();