summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2017-03-08 20:18:19 -0800
committerKaz Kylheku <kaz@kylheku.com>2017-03-08 20:18:19 -0800
commitceb931b6b1d86b93dcb964305fcf52f6fbee02df (patch)
treefc0e7d2c6d399725c7db7c990bcdc4766819d0f3
parentb480727df51c2e1ec89d9b154e652e690c9d0a21 (diff)
downloadtxr-ceb931b6b1d86b93dcb964305fcf52f6fbee02df.tar.gz
txr-ceb931b6b1d86b93dcb964305fcf52f6fbee02df.tar.bz2
txr-ceb931b6b1d86b93dcb964305fcf52f6fbee02df.zip
Don't sweep bad data source under the rug.
* match.c (open_data_source): If the data source isn't a string or stream, then error out.
-rw-r--r--match.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/match.c b/match.c
index d67f968b..cda3c28c 100644
--- a/match.c
+++ b/match.c
@@ -4423,7 +4423,7 @@ static void open_data_source(match_files_ctx *c)
if ((c->data = lazy_stream_cons(name)))
c->data_lineno = one;
} else {
- c->data = nil;
+ sem_error(specline, lit("~s doesn't denote a valid data source"), name, nao);
}
} else if (c->data == t && c->files == nil) {
if (opt_compat && opt_compat <= 170) {